diff --git a/docs/public/editor/autocomplete-data.json b/docs/public/editor/autocomplete-data.json index 6d505b79446..4de5e27da43 100644 --- a/docs/public/editor/autocomplete-data.json +++ b/docs/public/editor/autocomplete-data.json @@ -37,59 +37,6 @@ "type": "array", "desc": "Array of shared agentic workflow specifications to import.", "array": true - }, - "apm-packages": { - "type": "array|object", - "desc": "APM package references to install.", - "children": { - "packages": { - "type": "array", - "desc": "List of APM package references to install.", - "array": true - }, - "isolated": { - "type": "boolean", - "desc": "If true, agent restore step clears primitive dirs before unpacking.", - "enum": [true, false], - "leaf": true - }, - "github-app": { - "type": "object", - "desc": "GitHub App credentials for minting installation access tokens used by APM to access cross-org private repositories.", - "children": { - "app-id": { - "type": "string", - "desc": "GitHub App ID (e.g., '${{ vars.APP_ID }}').", - "leaf": true - }, - "private-key": { - "type": "string", - "desc": "GitHub App private key (e.g., '${{ secrets.APP_PRIVATE_KEY }}').", - "leaf": true - }, - "owner": { - "type": "string", - "desc": "Optional owner of the GitHub App installation (defaults to current repository owner if not specified)", - "leaf": true - }, - "repositories": { - "type": "array", - "desc": "Optional list of repositories to grant access to (defaults to current repository if not specified)", - "array": true - } - } - }, - "env": { - "type": "object", - "desc": "Environment variables to set on the APM pack step." - }, - "github-token": { - "type": "string", - "desc": "GitHub token expression to authenticate APM with private package repositories.", - "leaf": true - } - }, - "array": true } }, "array": true diff --git a/docs/src/content/docs/reference/frontmatter-full.md b/docs/src/content/docs/reference/frontmatter-full.md index 9d07a7b4f86..31d4d419e1e 100644 --- a/docs/src/content/docs/reference/frontmatter-full.md +++ b/docs/src/content/docs/reference/frontmatter-full.md @@ -63,8 +63,8 @@ metadata: {} # Workflow specifications to import. Supports array form (list of paths) or object -# form with 'aw' (agentic workflow paths) and 'apm-packages' (APM packages) -# subfields. Path resolution: (1) relative paths (e.g., 'shared/file.md') are +# form with 'aw' (agentic workflow paths) subfield. Path resolution: (1) relative +# paths (e.g., 'shared/file.md') are # resolved relative to the workflow's directory; (2) paths starting with # '.github/' or '/' are resolved from the repository root (repo-root-relative); # (3) paths matching 'owner/repo/path@ref' are fetched from GitHub at compile time @@ -81,53 +81,13 @@ imports: [] # Array items: undefined # Option 2: Object form of imports with 'aw' subfield for shared agentic workflow -# paths and 'apm-packages' subfield for APM packages. +# paths. imports: # Array of shared agentic workflow specifications to import. Format: # owner/repo/path@ref or relative paths. # (optional) aw: [] - # APM package references to install. Supports array format (list of package slugs) - # or object format with packages and configuration fields. Replaces the top-level - # 'dependencies' field. - # (optional) - # This field supports multiple formats (oneOf): - - # Option 1: Simple array of APM package references. - apm-packages: [] - # Array items: APM package reference in the format 'org/repo' or - # 'org/repo/path/to/skill' - - # Option 2: Object format with packages and optional configuration. - apm-packages: - # List of APM package references to install. - packages: [] - # Array of APM package reference in the format 'org/repo' or - # 'org/repo/path/to/skill' - - # If true, agent restore step clears primitive dirs before unpacking. - # (optional) - isolated: true - - # GitHub App credentials for minting installation access tokens used by APM to - # access cross-org private repositories. - # (optional) - # This field supports multiple formats (anyOf): - - # Option 1: undefined - - # Option 2: undefined - - # Environment variables to set on the APM pack step. - # (optional) - env: - {} - - # GitHub token expression to authenticate APM with private package repositories. - # (optional) - github-token: "${{ secrets.GITHUB_TOKEN }}" - # Optional list of additional workflow or action files that should be fetched # alongside this workflow when running 'gh aw add'. Entries are relative paths # (from the same directory as this workflow in the source repository) to agentic diff --git a/pkg/parser/import_bfs.go b/pkg/parser/import_bfs.go index 3667e996943..e68ee24180f 100644 --- a/pkg/parser/import_bfs.go +++ b/pkg/parser/import_bfs.go @@ -27,7 +27,7 @@ func processImportsFromFrontmatterWithManifestAndSource(frontmatter map[string]a log.Print("Processing imports from frontmatter with recursive BFS") // Parse imports field - can be array of strings or objects with path and inputs, - // or an object with 'aw' (agentic workflow paths) and 'apm-packages' subfields. + // or an object with an 'aw' (agentic workflow paths) subfield. var importSpecs []ImportSpec switch v := importsField.(type) { case []any: @@ -41,9 +41,8 @@ func processImportsFromFrontmatterWithManifestAndSource(frontmatter map[string]a importSpecs = append(importSpecs, ImportSpec{Path: s}) } case map[string]any: - // Object form: {aw: [...], apm-packages: [...]} + // Object form: {aw: [...]} // Extract 'aw' subfield for agentic workflow imports. - // The 'apm-packages' subfield is handled separately by extractAPMDependenciesFromFrontmatter. if awAny, hasAW := v["aw"]; hasAW { switch awVal := awAny.(type) { case []any: @@ -61,7 +60,7 @@ func processImportsFromFrontmatterWithManifestAndSource(frontmatter map[string]a } } default: - return nil, errors.New("imports field must be an array or an object with 'aw'/'apm-packages' subfields") + return nil, errors.New("imports field must be an array or an object with an 'aw' subfield") } if len(importSpecs) == 0 { diff --git a/pkg/parser/schemas/main_workflow_schema.json b/pkg/parser/schemas/main_workflow_schema.json index 60717883952..9014ccbb89e 100644 --- a/pkg/parser/schemas/main_workflow_schema.json +++ b/pkg/parser/schemas/main_workflow_schema.json @@ -71,7 +71,7 @@ ] }, "imports": { - "description": "Workflow specifications to import. Supports array form (list of paths) or object form with 'aw' (agentic workflow paths) and 'apm-packages' (APM packages) subfields. Path resolution: (1) relative paths (e.g., 'shared/file.md') are resolved relative to the workflow's directory; (2) paths starting with '.github/' or '/' are resolved from the repository root (repo-root-relative); (3) paths matching 'owner/repo/path@ref' are fetched from GitHub at compile time (cross-repo).", + "description": "Workflow specifications to import. Supports array form (list of paths) or object form with 'aw' (agentic workflow paths) subfield. Path resolution: (1) relative paths (e.g., 'shared/file.md') are resolved relative to the workflow's directory; (2) paths starting with '.github/' or '/' are resolved from the repository root (repo-root-relative); (3) paths matching 'owner/repo/path@ref' are fetched from GitHub at compile time (cross-repo).", "oneOf": [ { "type": "array", @@ -201,7 +201,7 @@ }, { "type": "object", - "description": "Object form of imports with 'aw' subfield for shared agentic workflow paths and 'apm-packages' subfield for APM packages.", + "description": "Object form of imports with 'aw' subfield for shared agentic workflow paths.", "additionalProperties": false, "properties": { "aw": { @@ -329,57 +329,6 @@ } ] } - }, - "apm-packages": { - "description": "APM package references to install. Supports array format (list of package slugs) or object format with packages and configuration fields. Replaces the top-level 'dependencies' field.", - "oneOf": [ - { - "type": "array", - "description": "Simple array of APM package references.", - "items": { - "type": "string", - "pattern": "^[a-zA-Z0-9_-]+/[a-zA-Z0-9_./-]+$", - "description": "APM package reference in the format 'org/repo' or 'org/repo/path/to/skill'" - } - }, - { - "type": "object", - "description": "Object format with packages and optional configuration.", - "properties": { - "packages": { - "type": "array", - "description": "List of APM package references to install.", - "items": { - "type": "string", - "pattern": "^[a-zA-Z0-9_-]+/[a-zA-Z0-9_./-]+$", - "description": "APM package reference in the format 'org/repo' or 'org/repo/path/to/skill'" - } - }, - "isolated": { - "type": "boolean", - "description": "If true, agent restore step clears primitive dirs before unpacking." - }, - "github-app": { - "$ref": "#/$defs/github_app", - "description": "GitHub App credentials for minting installation access tokens used by APM to access cross-org private repositories." - }, - "env": { - "type": "object", - "description": "Environment variables to set on the APM pack step.", - "additionalProperties": { - "type": "string" - } - }, - "github-token": { - "type": "string", - "description": "GitHub token expression to authenticate APM with private package repositories.", - "examples": ["${{ secrets.MY_TOKEN }}", "${{ secrets.GH_AW_GITHUB_TOKEN }}"] - } - }, - "required": ["packages"], - "additionalProperties": false - } - ] } } } @@ -398,17 +347,7 @@ } ], { - "aw": ["shared/common-tools.md", "shared/mcp/tavily.md"], - "apm-packages": ["microsoft/apm-sample-package"] - }, - { - "apm-packages": { - "packages": ["microsoft/apm-sample-package"], - "github-app": { - "client-id": "${{ vars.APP_ID }}", - "private-key": "${{ secrets.APP_PRIVATE_KEY }}" - } - } + "aw": ["shared/common-tools.md", "shared/mcp/tavily.md"] } ] },