@amodalai/core 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/dist/.last_build +0 -0
- package/dist/src/amodal-config.d.ts +194 -0
- package/dist/src/amodal-config.js +326 -0
- package/dist/src/amodal-config.js.map +1 -0
- package/dist/src/audit/audit-logger.d.ts +52 -0
- package/dist/src/audit/audit-logger.js +137 -0
- package/dist/src/audit/audit-logger.js.map +1 -0
- package/dist/src/audit/audit-outputs.d.ts +34 -0
- package/dist/src/audit/audit-outputs.js +73 -0
- package/dist/src/audit/audit-outputs.js.map +1 -0
- package/dist/src/audit/audit-redact.d.ts +14 -0
- package/dist/src/audit/audit-redact.js +55 -0
- package/dist/src/audit/audit-redact.js.map +1 -0
- package/dist/src/audit/audit-types.d.ts +122 -0
- package/dist/src/audit/audit-types.js +64 -0
- package/dist/src/audit/audit-types.js.map +1 -0
- package/dist/src/audit/index.d.ts +10 -0
- package/dist/src/audit/index.js +10 -0
- package/dist/src/audit/index.js.map +1 -0
- package/dist/src/eval/eval-cost.d.ts +33 -0
- package/dist/src/eval/eval-cost.js +73 -0
- package/dist/src/eval/eval-cost.js.map +1 -0
- package/dist/src/eval/eval-diff.d.ts +11 -0
- package/dist/src/eval/eval-diff.js +97 -0
- package/dist/src/eval/eval-diff.js.map +1 -0
- package/dist/src/eval/eval-formatter.d.ts +23 -0
- package/dist/src/eval/eval-formatter.js +221 -0
- package/dist/src/eval/eval-formatter.js.map +1 -0
- package/dist/src/eval/eval-judge.d.ts +26 -0
- package/dist/src/eval/eval-judge.js +76 -0
- package/dist/src/eval/eval-judge.js.map +1 -0
- package/dist/src/eval/eval-run-builder.d.ts +25 -0
- package/dist/src/eval/eval-run-builder.js +78 -0
- package/dist/src/eval/eval-run-builder.js.map +1 -0
- package/dist/src/eval/eval-runner.d.ts +36 -0
- package/dist/src/eval/eval-runner.js +92 -0
- package/dist/src/eval/eval-runner.js.map +1 -0
- package/dist/src/eval/eval-session-provider.d.ts +40 -0
- package/dist/src/eval/eval-session-provider.js +46 -0
- package/dist/src/eval/eval-session-provider.js.map +1 -0
- package/dist/src/eval/eval-types.d.ts +146 -0
- package/dist/src/eval/eval-types.js +7 -0
- package/dist/src/eval/eval-types.js.map +1 -0
- package/dist/src/eval/experiment-runner.d.ts +16 -0
- package/dist/src/eval/experiment-runner.js +73 -0
- package/dist/src/eval/experiment-runner.js.map +1 -0
- package/dist/src/eval/experiment-types.d.ts +56 -0
- package/dist/src/eval/experiment-types.js +7 -0
- package/dist/src/eval/experiment-types.js.map +1 -0
- package/dist/src/eval/index.d.ts +22 -0
- package/dist/src/eval/index.js +18 -0
- package/dist/src/eval/index.js.map +1 -0
- package/dist/src/eval/multi-model-runner.d.ts +42 -0
- package/dist/src/eval/multi-model-runner.js +70 -0
- package/dist/src/eval/multi-model-runner.js.map +1 -0
- package/dist/src/eval/platform-eval-client.d.ts +105 -0
- package/dist/src/eval/platform-eval-client.js +155 -0
- package/dist/src/eval/platform-eval-client.js.map +1 -0
- package/dist/src/index.d.ts +41 -0
- package/dist/src/index.js +68 -0
- package/dist/src/index.js.map +1 -0
- package/dist/src/knowledge/index.d.ts +11 -0
- package/dist/src/knowledge/index.js +12 -0
- package/dist/src/knowledge/index.js.map +1 -0
- package/dist/src/knowledge/kb-formatter.d.ts +15 -0
- package/dist/src/knowledge/kb-formatter.js +78 -0
- package/dist/src/knowledge/kb-formatter.js.map +1 -0
- package/dist/src/knowledge/kb-index.d.ts +27 -0
- package/dist/src/knowledge/kb-index.js +66 -0
- package/dist/src/knowledge/kb-index.js.map +1 -0
- package/dist/src/knowledge/kb-types.d.ts +54 -0
- package/dist/src/knowledge/kb-types.js +7 -0
- package/dist/src/knowledge/kb-types.js.map +1 -0
- package/dist/src/knowledge/knowledge-store.d.ts +56 -0
- package/dist/src/knowledge/knowledge-store.js +141 -0
- package/dist/src/knowledge/knowledge-store.js.map +1 -0
- package/dist/src/knowledge/load-knowledge.d.ts +30 -0
- package/dist/src/knowledge/load-knowledge.js +161 -0
- package/dist/src/knowledge/load-knowledge.js.map +1 -0
- package/dist/src/knowledge/propose-kb-update.d.ts +32 -0
- package/dist/src/knowledge/propose-kb-update.js +148 -0
- package/dist/src/knowledge/propose-kb-update.js.map +1 -0
- package/dist/src/knowledge/propose-knowledge.d.ts +34 -0
- package/dist/src/knowledge/propose-knowledge.js +163 -0
- package/dist/src/knowledge/propose-knowledge.js.map +1 -0
- package/dist/src/mcp/index.d.ts +7 -0
- package/dist/src/mcp/index.js +7 -0
- package/dist/src/mcp/index.js.map +1 -0
- package/dist/src/mcp/mcp-manager.d.ts +96 -0
- package/dist/src/mcp/mcp-manager.js +192 -0
- package/dist/src/mcp/mcp-manager.js.map +1 -0
- package/dist/src/packages/config-deps.d.ts +20 -0
- package/dist/src/packages/config-deps.js +77 -0
- package/dist/src/packages/config-deps.js.map +1 -0
- package/dist/src/packages/env-file.d.ts +28 -0
- package/dist/src/packages/env-file.js +143 -0
- package/dist/src/packages/env-file.js.map +1 -0
- package/dist/src/packages/frontmatter.d.ts +28 -0
- package/dist/src/packages/frontmatter.js +77 -0
- package/dist/src/packages/frontmatter.js.map +1 -0
- package/dist/src/packages/index.d.ts +16 -0
- package/dist/src/packages/index.js +17 -0
- package/dist/src/packages/index.js.map +1 -0
- package/dist/src/packages/lock-file.d.ts +35 -0
- package/dist/src/packages/lock-file.js +117 -0
- package/dist/src/packages/lock-file.js.map +1 -0
- package/dist/src/packages/manifest-reader.d.ts +19 -0
- package/dist/src/packages/manifest-reader.js +91 -0
- package/dist/src/packages/manifest-reader.js.map +1 -0
- package/dist/src/packages/merge-engine.d.ts +63 -0
- package/dist/src/packages/merge-engine.js +357 -0
- package/dist/src/packages/merge-engine.js.map +1 -0
- package/dist/src/packages/npm-context.d.ts +56 -0
- package/dist/src/packages/npm-context.js +235 -0
- package/dist/src/packages/npm-context.js.map +1 -0
- package/dist/src/packages/npm-registry.d.ts +35 -0
- package/dist/src/packages/npm-registry.js +107 -0
- package/dist/src/packages/npm-registry.js.map +1 -0
- package/dist/src/packages/package-error.d.ts +16 -0
- package/dist/src/packages/package-error.js +17 -0
- package/dist/src/packages/package-error.js.map +1 -0
- package/dist/src/packages/package-types.d.ts +477 -0
- package/dist/src/packages/package-types.js +156 -0
- package/dist/src/packages/package-types.js.map +1 -0
- package/dist/src/packages/resolver.d.ts +41 -0
- package/dist/src/packages/resolver.js +353 -0
- package/dist/src/packages/resolver.js.map +1 -0
- package/dist/src/platform/config-builder.d.ts +24 -0
- package/dist/src/platform/config-builder.js +70 -0
- package/dist/src/platform/config-builder.js.map +1 -0
- package/dist/src/platform/index.d.ts +8 -0
- package/dist/src/platform/index.js +9 -0
- package/dist/src/platform/index.js.map +1 -0
- package/dist/src/platform/platform-client.d.ts +160 -0
- package/dist/src/platform/platform-client.js +486 -0
- package/dist/src/platform/platform-client.js.map +1 -0
- package/dist/src/platform/platform-types.d.ts +81 -0
- package/dist/src/platform/platform-types.js +18 -0
- package/dist/src/platform/platform-types.js.map +1 -0
- package/dist/src/providers/content-generator/google-to-llm.d.ts +87 -0
- package/dist/src/providers/content-generator/google-to-llm.js +226 -0
- package/dist/src/providers/content-generator/google-to-llm.js.map +1 -0
- package/dist/src/providers/content-generator/index.d.ts +10 -0
- package/dist/src/providers/content-generator/index.js +9 -0
- package/dist/src/providers/content-generator/index.js.map +1 -0
- package/dist/src/providers/content-generator/llm-to-google.d.ts +59 -0
- package/dist/src/providers/content-generator/llm-to-google.js +178 -0
- package/dist/src/providers/content-generator/llm-to-google.js.map +1 -0
- package/dist/src/providers/content-generator/multi-provider-content-generator.d.ts +61 -0
- package/dist/src/providers/content-generator/multi-provider-content-generator.js +144 -0
- package/dist/src/providers/content-generator/multi-provider-content-generator.js.map +1 -0
- package/dist/src/providers/runtime/anthropic-provider.d.ts +18 -0
- package/dist/src/providers/runtime/anthropic-provider.js +253 -0
- package/dist/src/providers/runtime/anthropic-provider.js.map +1 -0
- package/dist/src/providers/runtime/azure-provider.d.ts +25 -0
- package/dist/src/providers/runtime/azure-provider.js +206 -0
- package/dist/src/providers/runtime/azure-provider.js.map +1 -0
- package/dist/src/providers/runtime/bedrock-provider.d.ts +22 -0
- package/dist/src/providers/runtime/bedrock-provider.js +276 -0
- package/dist/src/providers/runtime/bedrock-provider.js.map +1 -0
- package/dist/src/providers/runtime/failover-provider.d.ts +30 -0
- package/dist/src/providers/runtime/failover-provider.js +124 -0
- package/dist/src/providers/runtime/failover-provider.js.map +1 -0
- package/dist/src/providers/runtime/google-provider.d.ts +17 -0
- package/dist/src/providers/runtime/google-provider.js +239 -0
- package/dist/src/providers/runtime/google-provider.js.map +1 -0
- package/dist/src/providers/runtime/index.d.ts +16 -0
- package/dist/src/providers/runtime/index.js +16 -0
- package/dist/src/providers/runtime/index.js.map +1 -0
- package/dist/src/providers/runtime/openai-provider.d.ts +21 -0
- package/dist/src/providers/runtime/openai-provider.js +266 -0
- package/dist/src/providers/runtime/openai-provider.js.map +1 -0
- package/dist/src/providers/runtime/provider-errors.d.ts +39 -0
- package/dist/src/providers/runtime/provider-errors.js +50 -0
- package/dist/src/providers/runtime/provider-errors.js.map +1 -0
- package/dist/src/providers/runtime/provider-factory.d.ts +19 -0
- package/dist/src/providers/runtime/provider-factory.js +45 -0
- package/dist/src/providers/runtime/provider-factory.js.map +1 -0
- package/dist/src/providers/runtime/runtime-provider-types.d.ts +63 -0
- package/dist/src/providers/runtime/runtime-provider-types.js +7 -0
- package/dist/src/providers/runtime/runtime-provider-types.js.map +1 -0
- package/dist/src/providers/runtime/streaming-types.d.ts +40 -0
- package/dist/src/providers/runtime/streaming-types.js +7 -0
- package/dist/src/providers/runtime/streaming-types.js.map +1 -0
- package/dist/src/repo/config-schema.d.ts +238 -0
- package/dist/src/repo/config-schema.js +155 -0
- package/dist/src/repo/config-schema.js.map +1 -0
- package/dist/src/repo/connection-schemas.d.ts +449 -0
- package/dist/src/repo/connection-schemas.js +109 -0
- package/dist/src/repo/connection-schemas.js.map +1 -0
- package/dist/src/repo/connection-types.d.ts +29 -0
- package/dist/src/repo/connection-types.js +7 -0
- package/dist/src/repo/connection-types.js.map +1 -0
- package/dist/src/repo/drift-detector.d.ts +26 -0
- package/dist/src/repo/drift-detector.js +66 -0
- package/dist/src/repo/drift-detector.js.map +1 -0
- package/dist/src/repo/graphql-drift-detector.d.ts +27 -0
- package/dist/src/repo/graphql-drift-detector.js +66 -0
- package/dist/src/repo/graphql-drift-detector.js.map +1 -0
- package/dist/src/repo/graphql-parser.d.ts +30 -0
- package/dist/src/repo/graphql-parser.js +125 -0
- package/dist/src/repo/graphql-parser.js.map +1 -0
- package/dist/src/repo/graphql-surface-parser.d.ts +20 -0
- package/dist/src/repo/graphql-surface-parser.js +74 -0
- package/dist/src/repo/graphql-surface-parser.js.map +1 -0
- package/dist/src/repo/index.d.ts +30 -0
- package/dist/src/repo/index.js +29 -0
- package/dist/src/repo/index.js.map +1 -0
- package/dist/src/repo/local-reader.d.ts +10 -0
- package/dist/src/repo/local-reader.js +299 -0
- package/dist/src/repo/local-reader.js.map +1 -0
- package/dist/src/repo/openapi-parser.d.ts +35 -0
- package/dist/src/repo/openapi-parser.js +93 -0
- package/dist/src/repo/openapi-parser.js.map +1 -0
- package/dist/src/repo/parsers.d.ts +91 -0
- package/dist/src/repo/parsers.js +454 -0
- package/dist/src/repo/parsers.js.map +1 -0
- package/dist/src/repo/platform-reader.d.ts +10 -0
- package/dist/src/repo/platform-reader.js +206 -0
- package/dist/src/repo/platform-reader.js.map +1 -0
- package/dist/src/repo/repo-loader.d.ts +14 -0
- package/dist/src/repo/repo-loader.js +25 -0
- package/dist/src/repo/repo-loader.js.map +1 -0
- package/dist/src/repo/repo-types.d.ts +159 -0
- package/dist/src/repo/repo-types.js +17 -0
- package/dist/src/repo/repo-types.js.map +1 -0
- package/dist/src/repo/spec-syncer.d.ts +30 -0
- package/dist/src/repo/spec-syncer.js +85 -0
- package/dist/src/repo/spec-syncer.js.map +1 -0
- package/dist/src/repo/store-loader.d.ts +19 -0
- package/dist/src/repo/store-loader.js +94 -0
- package/dist/src/repo/store-loader.js.map +1 -0
- package/dist/src/repo/store-schemas.d.ts +313 -0
- package/dist/src/repo/store-schemas.js +103 -0
- package/dist/src/repo/store-schemas.js.map +1 -0
- package/dist/src/repo/store-tool-schema.d.ts +29 -0
- package/dist/src/repo/store-tool-schema.js +103 -0
- package/dist/src/repo/store-tool-schema.js.map +1 -0
- package/dist/src/repo/store-types.d.ts +91 -0
- package/dist/src/repo/store-types.js +7 -0
- package/dist/src/repo/store-types.js.map +1 -0
- package/dist/src/repo/surface-parser.d.ts +17 -0
- package/dist/src/repo/surface-parser.js +75 -0
- package/dist/src/repo/surface-parser.js.map +1 -0
- package/dist/src/repo/tool-loader.d.ts +33 -0
- package/dist/src/repo/tool-loader.js +240 -0
- package/dist/src/repo/tool-loader.js.map +1 -0
- package/dist/src/repo/tool-types.d.ts +205 -0
- package/dist/src/repo/tool-types.js +61 -0
- package/dist/src/repo/tool-types.js.map +1 -0
- package/dist/src/roles/index.d.ts +7 -0
- package/dist/src/roles/index.js +8 -0
- package/dist/src/roles/index.js.map +1 -0
- package/dist/src/roles/role-filter.d.ts +33 -0
- package/dist/src/roles/role-filter.js +55 -0
- package/dist/src/roles/role-filter.js.map +1 -0
- package/dist/src/roles/role-types.d.ts +76 -0
- package/dist/src/roles/role-types.js +38 -0
- package/dist/src/roles/role-types.js.map +1 -0
- package/dist/src/runtime/connection-bridge.d.ts +19 -0
- package/dist/src/runtime/connection-bridge.js +103 -0
- package/dist/src/runtime/connection-bridge.js.map +1 -0
- package/dist/src/runtime/context-compiler.d.ts +35 -0
- package/dist/src/runtime/context-compiler.js +183 -0
- package/dist/src/runtime/context-compiler.js.map +1 -0
- package/dist/src/runtime/default-prompt.d.ts +28 -0
- package/dist/src/runtime/default-prompt.js +71 -0
- package/dist/src/runtime/default-prompt.js.map +1 -0
- package/dist/src/runtime/explore-tool.d.ts +96 -0
- package/dist/src/runtime/explore-tool.js +111 -0
- package/dist/src/runtime/explore-tool.js.map +1 -0
- package/dist/src/runtime/index.d.ts +26 -0
- package/dist/src/runtime/index.js +19 -0
- package/dist/src/runtime/index.js.map +1 -0
- package/dist/src/runtime/output-pipeline.d.ts +62 -0
- package/dist/src/runtime/output-pipeline.js +69 -0
- package/dist/src/runtime/output-pipeline.js.map +1 -0
- package/dist/src/runtime/plan-mode.d.ts +39 -0
- package/dist/src/runtime/plan-mode.js +81 -0
- package/dist/src/runtime/plan-mode.js.map +1 -0
- package/dist/src/runtime/preference-client.d.ts +39 -0
- package/dist/src/runtime/preference-client.js +70 -0
- package/dist/src/runtime/preference-client.js.map +1 -0
- package/dist/src/runtime/preference-detector.d.ts +22 -0
- package/dist/src/runtime/preference-detector.js +95 -0
- package/dist/src/runtime/preference-detector.js.map +1 -0
- package/dist/src/runtime/request-integration.d.ts +18 -0
- package/dist/src/runtime/request-integration.js +36 -0
- package/dist/src/runtime/request-integration.js.map +1 -0
- package/dist/src/runtime/runtime-types.d.ts +48 -0
- package/dist/src/runtime/runtime-types.js +7 -0
- package/dist/src/runtime/runtime-types.js.map +1 -0
- package/dist/src/runtime/session-setup.d.ts +53 -0
- package/dist/src/runtime/session-setup.js +90 -0
- package/dist/src/runtime/session-setup.js.map +1 -0
- package/dist/src/runtime/telemetry-client.d.ts +39 -0
- package/dist/src/runtime/telemetry-client.js +87 -0
- package/dist/src/runtime/telemetry-client.js.map +1 -0
- package/dist/src/runtime/telemetry-hooks.d.ts +47 -0
- package/dist/src/runtime/telemetry-hooks.js +115 -0
- package/dist/src/runtime/telemetry-hooks.js.map +1 -0
- package/dist/src/runtime/token-allocator.d.ts +34 -0
- package/dist/src/runtime/token-allocator.js +86 -0
- package/dist/src/runtime/token-allocator.js.map +1 -0
- package/dist/src/runtime/user-context.d.ts +49 -0
- package/dist/src/runtime/user-context.js +135 -0
- package/dist/src/runtime/user-context.js.map +1 -0
- package/dist/src/sdk.d.ts +57 -0
- package/dist/src/sdk.js +377 -0
- package/dist/src/sdk.js.map +1 -0
- package/dist/src/security/action-gate.d.ts +23 -0
- package/dist/src/security/action-gate.js +78 -0
- package/dist/src/security/action-gate.js.map +1 -0
- package/dist/src/security/field-scrubber.d.ts +27 -0
- package/dist/src/security/field-scrubber.js +152 -0
- package/dist/src/security/field-scrubber.js.map +1 -0
- package/dist/src/security/index.d.ts +14 -0
- package/dist/src/security/index.js +15 -0
- package/dist/src/security/index.js.map +1 -0
- package/dist/src/security/leak-detector.d.ts +23 -0
- package/dist/src/security/leak-detector.js +51 -0
- package/dist/src/security/leak-detector.js.map +1 -0
- package/dist/src/security/output-guard.d.ts +33 -0
- package/dist/src/security/output-guard.js +118 -0
- package/dist/src/security/output-guard.js.map +1 -0
- package/dist/src/security/pattern-scanner.d.ts +19 -0
- package/dist/src/security/pattern-scanner.js +66 -0
- package/dist/src/security/pattern-scanner.js.map +1 -0
- package/dist/src/security/scope-checker.d.ts +27 -0
- package/dist/src/security/scope-checker.js +52 -0
- package/dist/src/security/scope-checker.js.map +1 -0
- package/dist/src/security/scrub-tracker.d.ts +21 -0
- package/dist/src/security/scrub-tracker.js +39 -0
- package/dist/src/security/scrub-tracker.js.map +1 -0
- package/dist/src/security/security-types.d.ts +69 -0
- package/dist/src/security/security-types.js +17 -0
- package/dist/src/security/security-types.js.map +1 -0
- package/dist/src/security/threshold-evaluator.d.ts +13 -0
- package/dist/src/security/threshold-evaluator.js +44 -0
- package/dist/src/security/threshold-evaluator.js.map +1 -0
- package/dist/src/snapshot/index.d.ts +8 -0
- package/dist/src/snapshot/index.js +9 -0
- package/dist/src/snapshot/index.js.map +1 -0
- package/dist/src/snapshot/snapshot-builder.d.ts +37 -0
- package/dist/src/snapshot/snapshot-builder.js +152 -0
- package/dist/src/snapshot/snapshot-builder.js.map +1 -0
- package/dist/src/snapshot/snapshot-loader.d.ts +29 -0
- package/dist/src/snapshot/snapshot-loader.js +188 -0
- package/dist/src/snapshot/snapshot-loader.js.map +1 -0
- package/dist/src/snapshot/snapshot-types.d.ts +1940 -0
- package/dist/src/snapshot/snapshot-types.js +145 -0
- package/dist/src/snapshot/snapshot-types.js.map +1 -0
- package/dist/src/stores/index.d.ts +6 -0
- package/dist/src/stores/index.js +7 -0
- package/dist/src/stores/index.js.map +1 -0
- package/dist/src/stores/store-backend.d.ts +135 -0
- package/dist/src/stores/store-backend.js +7 -0
- package/dist/src/stores/store-backend.js.map +1 -0
- package/dist/src/templates/connections.d.ts +14 -0
- package/dist/src/templates/connections.js +7 -0
- package/dist/src/templates/connections.js.map +1 -0
- package/dist/src/templates/index.d.ts +7 -0
- package/dist/src/templates/index.js +8 -0
- package/dist/src/templates/index.js.map +1 -0
- package/dist/src/templates/template-resolver.d.ts +45 -0
- package/dist/src/templates/template-resolver.js +121 -0
- package/dist/src/templates/template-resolver.js.map +1 -0
- package/dist/src/tool-context.d.ts +33 -0
- package/dist/src/tool-context.js +7 -0
- package/dist/src/tool-context.js.map +1 -0
- package/dist/src/tool-registration.d.ts +14 -0
- package/dist/src/tool-registration.js +51 -0
- package/dist/src/tool-registration.js.map +1 -0
- package/dist/src/tools/amodal-tool-errors.d.ts +24 -0
- package/dist/src/tools/amodal-tool-errors.js +28 -0
- package/dist/src/tools/amodal-tool-errors.js.map +1 -0
- package/dist/src/tools/amodal-tool-names.d.ts +14 -0
- package/dist/src/tools/amodal-tool-names.js +15 -0
- package/dist/src/tools/amodal-tool-names.js.map +1 -0
- package/dist/src/tools/chain-tool-registry.d.ts +20 -0
- package/dist/src/tools/chain-tool-registry.js +49 -0
- package/dist/src/tools/chain-tool-registry.js.map +1 -0
- package/dist/src/tools/chain-tool-types.d.ts +190 -0
- package/dist/src/tools/chain-tool-types.js +50 -0
- package/dist/src/tools/chain-tool-types.js.map +1 -0
- package/dist/src/tools/chain-tool.d.ts +34 -0
- package/dist/src/tools/chain-tool.js +294 -0
- package/dist/src/tools/chain-tool.js.map +1 -0
- package/dist/src/tools/custom-tool-registrar.d.ts +8 -0
- package/dist/src/tools/custom-tool-registrar.js +10 -0
- package/dist/src/tools/custom-tool-registrar.js.map +1 -0
- package/dist/src/tools/definitions/amodal-tools.d.ts +9 -0
- package/dist/src/tools/definitions/amodal-tools.js +192 -0
- package/dist/src/tools/definitions/amodal-tools.js.map +1 -0
- package/dist/src/tools/function-tool-registry.d.ts +22 -0
- package/dist/src/tools/function-tool-registry.js +45 -0
- package/dist/src/tools/function-tool-registry.js.map +1 -0
- package/dist/src/tools/function-tool-types.d.ts +76 -0
- package/dist/src/tools/function-tool-types.js +27 -0
- package/dist/src/tools/function-tool-types.js.map +1 -0
- package/dist/src/tools/function-tool.d.ts +34 -0
- package/dist/src/tools/function-tool.js +97 -0
- package/dist/src/tools/function-tool.js.map +1 -0
- package/dist/src/tools/http-tool-registry.d.ts +20 -0
- package/dist/src/tools/http-tool-registry.js +34 -0
- package/dist/src/tools/http-tool-registry.js.map +1 -0
- package/dist/src/tools/http-tool-types.d.ts +92 -0
- package/dist/src/tools/http-tool-types.js +44 -0
- package/dist/src/tools/http-tool-types.js.map +1 -0
- package/dist/src/tools/http-tool.d.ts +32 -0
- package/dist/src/tools/http-tool.js +176 -0
- package/dist/src/tools/http-tool.js.map +1 -0
- package/dist/src/tools/merge-template.d.ts +33 -0
- package/dist/src/tools/merge-template.js +65 -0
- package/dist/src/tools/merge-template.js.map +1 -0
- package/dist/src/tools/request-tool-types.d.ts +46 -0
- package/dist/src/tools/request-tool-types.js +20 -0
- package/dist/src/tools/request-tool-types.js.map +1 -0
- package/dist/src/tools/request-tool.d.ts +29 -0
- package/dist/src/tools/request-tool.js +268 -0
- package/dist/src/tools/request-tool.js.map +1 -0
- package/dist/src/tools/store-query-tool.d.ts +29 -0
- package/dist/src/tools/store-query-tool.js +82 -0
- package/dist/src/tools/store-query-tool.js.map +1 -0
- package/dist/src/tools/store-write-tool.d.ts +26 -0
- package/dist/src/tools/store-write-tool.js +84 -0
- package/dist/src/tools/store-write-tool.js.map +1 -0
- package/dist/src/tools/tool-definition-types.d.ts +21 -0
- package/dist/src/tools/tool-definition-types.js +7 -0
- package/dist/src/tools/tool-definition-types.js.map +1 -0
- package/dist/src/tools/tool-utils.d.ts +29 -0
- package/dist/src/tools/tool-utils.js +66 -0
- package/dist/src/tools/tool-utils.js.map +1 -0
- package/dist/src/versions/bundle-loader.d.ts +37 -0
- package/dist/src/versions/bundle-loader.js +99 -0
- package/dist/src/versions/bundle-loader.js.map +1 -0
- package/dist/src/versions/dependency-manager.d.ts +54 -0
- package/dist/src/versions/dependency-manager.js +132 -0
- package/dist/src/versions/dependency-manager.js.map +1 -0
- package/dist/src/versions/handler-loader.d.ts +27 -0
- package/dist/src/versions/handler-loader.js +62 -0
- package/dist/src/versions/handler-loader.js.map +1 -0
- package/dist/src/versions/index.d.ts +10 -0
- package/dist/src/versions/index.js +11 -0
- package/dist/src/versions/index.js.map +1 -0
- package/dist/src/versions/version-bundle-types.d.ts +1278 -0
- package/dist/src/versions/version-bundle-types.js +207 -0
- package/dist/src/versions/version-bundle-types.js.map +1 -0
- package/dist/src/versions/version-manager.d.ts +89 -0
- package/dist/src/versions/version-manager.js +124 -0
- package/dist/src/versions/version-manager.js.map +1 -0
- package/dist/src/widgets/index.d.ts +8 -0
- package/dist/src/widgets/index.js +8 -0
- package/dist/src/widgets/index.js.map +1 -0
- package/dist/src/widgets/present-tool.d.ts +21 -0
- package/dist/src/widgets/present-tool.js +107 -0
- package/dist/src/widgets/present-tool.js.map +1 -0
- package/dist/src/widgets/widget-types.d.ts +78 -0
- package/dist/src/widgets/widget-types.js +28 -0
- package/dist/src/widgets/widget-types.js.map +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -0
- package/package.json +50 -0
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Amodal Labs, Inc.
|
|
4
|
+
* SPDX-License-Identifier: MIT
|
|
5
|
+
*/
|
|
6
|
+
/**
|
|
7
|
+
* Compare parsed OpenAPI spec endpoints against surface endpoint definitions.
|
|
8
|
+
* Returns a drift result showing added, removed, changed, and unchanged endpoints.
|
|
9
|
+
*/
|
|
10
|
+
export function detectDrift(specEndpoints, surfaceEndpoints) {
|
|
11
|
+
// Build lookup maps
|
|
12
|
+
const specMap = new Map();
|
|
13
|
+
for (const ep of specEndpoints) {
|
|
14
|
+
specMap.set(endpointKey(ep.method, ep.path), ep);
|
|
15
|
+
}
|
|
16
|
+
const surfaceMap = new Map();
|
|
17
|
+
for (const ep of surfaceEndpoints) {
|
|
18
|
+
surfaceMap.set(endpointKey(ep.method, ep.path), ep);
|
|
19
|
+
}
|
|
20
|
+
const added = [];
|
|
21
|
+
const removed = [];
|
|
22
|
+
const changed = [];
|
|
23
|
+
const unchanged = [];
|
|
24
|
+
// Check for added/changed endpoints (in spec but not in surface, or different)
|
|
25
|
+
for (const [key, specEp] of specMap) {
|
|
26
|
+
const surfaceEp = surfaceMap.get(key);
|
|
27
|
+
if (!surfaceEp) {
|
|
28
|
+
added.push(specEp);
|
|
29
|
+
continue;
|
|
30
|
+
}
|
|
31
|
+
// Compare
|
|
32
|
+
const changes = compareEndpoints(specEp, surfaceEp);
|
|
33
|
+
if (changes.length > 0) {
|
|
34
|
+
changed.push({ endpoint: key, changes });
|
|
35
|
+
}
|
|
36
|
+
else {
|
|
37
|
+
unchanged.push(key);
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
// Check for removed endpoints (in surface but not in spec)
|
|
41
|
+
for (const [key, surfaceEp] of surfaceMap) {
|
|
42
|
+
if (!specMap.has(key)) {
|
|
43
|
+
removed.push(surfaceEp);
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
return { added, removed, changed, unchanged };
|
|
47
|
+
}
|
|
48
|
+
function endpointKey(method, path) {
|
|
49
|
+
return `${method.toUpperCase()} ${path}`;
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* Compare a spec endpoint with a surface endpoint and return a list of changes.
|
|
53
|
+
*/
|
|
54
|
+
function compareEndpoints(spec, surface) {
|
|
55
|
+
const changes = [];
|
|
56
|
+
// Check deprecation
|
|
57
|
+
if (spec.deprecated) {
|
|
58
|
+
changes.push('deprecated in spec');
|
|
59
|
+
}
|
|
60
|
+
// Check description/summary changes
|
|
61
|
+
if (spec.summary && surface.description && spec.summary !== surface.description) {
|
|
62
|
+
changes.push('description updated');
|
|
63
|
+
}
|
|
64
|
+
return changes;
|
|
65
|
+
}
|
|
66
|
+
//# sourceMappingURL=drift-detector.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"drift-detector.js","sourceRoot":"","sources":["../../../src/repo/drift-detector.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAqBH;;;GAGG;AACH,MAAM,UAAU,WAAW,CACzB,aAA+B,EAC/B,gBAAmC;IAEnC,oBAAoB;IACpB,MAAM,OAAO,GAAG,IAAI,GAAG,EAA0B,CAAC;IAClD,KAAK,MAAM,EAAE,IAAI,aAAa,EAAE,CAAC;QAC/B,OAAO,CAAC,GAAG,CAAC,WAAW,CAAC,EAAE,CAAC,MAAM,EAAE,EAAE,CAAC,IAAI,CAAC,EAAE,EAAE,CAAC,CAAC;IACnD,CAAC;IAED,MAAM,UAAU,GAAG,IAAI,GAAG,EAA2B,CAAC;IACtD,KAAK,MAAM,EAAE,IAAI,gBAAgB,EAAE,CAAC;QAClC,UAAU,CAAC,GAAG,CAAC,WAAW,CAAC,EAAE,CAAC,MAAM,EAAE,EAAE,CAAC,IAAI,CAAC,EAAE,EAAE,CAAC,CAAC;IACtD,CAAC;IAED,MAAM,KAAK,GAAqB,EAAE,CAAC;IACnC,MAAM,OAAO,GAAsB,EAAE,CAAC;IACtC,MAAM,OAAO,GAAqB,EAAE,CAAC;IACrC,MAAM,SAAS,GAAa,EAAE,CAAC;IAE/B,+EAA+E;IAC/E,KAAK,MAAM,CAAC,GAAG,EAAE,MAAM,CAAC,IAAI,OAAO,EAAE,CAAC;QACpC,MAAM,SAAS,GAAG,UAAU,CAAC,GAAG,CAAC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I,CAAC,qBAAqB,CAAC,CAAC;IACtC,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Amodal Labs, Inc.
|
|
4
|
+
* SPDX-License-Identifier: MIT
|
|
5
|
+
*/
|
|
6
|
+
import type { ParsedGraphQLOperation } from './graphql-parser.js';
|
|
7
|
+
import type { SurfaceEndpoint } from './connection-types.js';
|
|
8
|
+
export interface GraphQLDriftResult {
|
|
9
|
+
added: ParsedGraphQLOperation[];
|
|
10
|
+
removed: SurfaceEndpoint[];
|
|
11
|
+
changed: GraphQLOperationChange[];
|
|
12
|
+
unchanged: string[];
|
|
13
|
+
}
|
|
14
|
+
export interface GraphQLOperationChange {
|
|
15
|
+
name: string;
|
|
16
|
+
operationType: string;
|
|
17
|
+
changes: string[];
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* Detect drift between a parsed GraphQL schema and a surface definition.
|
|
21
|
+
*
|
|
22
|
+
* - Added: in schema but not in surface
|
|
23
|
+
* - Removed: in surface but not in schema
|
|
24
|
+
* - Changed: in both but with differences (e.g., description changed)
|
|
25
|
+
* - Unchanged: in both with no differences
|
|
26
|
+
*/
|
|
27
|
+
export declare function detectGraphQLDrift(schemaOps: ParsedGraphQLOperation[], surfaceEndpoints: SurfaceEndpoint[]): GraphQLDriftResult;
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Amodal Labs, Inc.
|
|
4
|
+
* SPDX-License-Identifier: MIT
|
|
5
|
+
*/
|
|
6
|
+
/**
|
|
7
|
+
* Detect drift between a parsed GraphQL schema and a surface definition.
|
|
8
|
+
*
|
|
9
|
+
* - Added: in schema but not in surface
|
|
10
|
+
* - Removed: in surface but not in schema
|
|
11
|
+
* - Changed: in both but with differences (e.g., description changed)
|
|
12
|
+
* - Unchanged: in both with no differences
|
|
13
|
+
*/
|
|
14
|
+
export function detectGraphQLDrift(schemaOps, surfaceEndpoints) {
|
|
15
|
+
const schemaMap = new Map();
|
|
16
|
+
for (const op of schemaOps) {
|
|
17
|
+
schemaMap.set(operationKey(op.operationType, op.name), op);
|
|
18
|
+
}
|
|
19
|
+
const surfaceMap = new Map();
|
|
20
|
+
for (const ep of surfaceEndpoints) {
|
|
21
|
+
surfaceMap.set(operationKey(ep.method, ep.path), ep);
|
|
22
|
+
}
|
|
23
|
+
const added = [];
|
|
24
|
+
const changed = [];
|
|
25
|
+
const unchanged = [];
|
|
26
|
+
for (const [key, op] of schemaMap) {
|
|
27
|
+
const surface = surfaceMap.get(key);
|
|
28
|
+
if (!surface) {
|
|
29
|
+
added.push(op);
|
|
30
|
+
}
|
|
31
|
+
else {
|
|
32
|
+
const changes = compareOperation(op, surface);
|
|
33
|
+
if (changes.length > 0) {
|
|
34
|
+
changed.push({
|
|
35
|
+
name: op.name,
|
|
36
|
+
operationType: op.operationType,
|
|
37
|
+
changes,
|
|
38
|
+
});
|
|
39
|
+
}
|
|
40
|
+
else {
|
|
41
|
+
unchanged.push(key);
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
const removed = [];
|
|
46
|
+
for (const [key, ep] of surfaceMap) {
|
|
47
|
+
if (!schemaMap.has(key)) {
|
|
48
|
+
removed.push(ep);
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
return { added, removed, changed, unchanged };
|
|
52
|
+
}
|
|
53
|
+
function operationKey(operationType, name) {
|
|
54
|
+
return `${operationType.toUpperCase()} ${name}`;
|
|
55
|
+
}
|
|
56
|
+
function compareOperation(schemaOp, surfaceEp) {
|
|
57
|
+
const changes = [];
|
|
58
|
+
// Compare descriptions (if both present)
|
|
59
|
+
if (schemaOp.description &&
|
|
60
|
+
surfaceEp.description &&
|
|
61
|
+
schemaOp.description !== surfaceEp.description) {
|
|
62
|
+
changes.push('description changed');
|
|
63
|
+
}
|
|
64
|
+
return changes;
|
|
65
|
+
}
|
|
66
|
+
//# sourceMappingURL=graphql-drift-detector.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"graphql-drift-detector.js","sourceRoot":"","sources":["../../../src/repo/graphql-drift-detector.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAkBH;;;;;;;GAOG;AACH,MAAM,UAAU,kBAAkB,CAChC,SAAmC,EACnC,gBAAmC;IAEnC,MAAM,SAAS,GAAG,IAAI,GAAG,EAAkC,CAAC;IAC5D,KAAK,MAAM,EAAE,IAAI,SAAS,EAAE,CAAC;QAC3B,SAAS,CAAC,GAAG,CAAC,YAAY,CAAC,EAAE,CAAC,aAAa,EAAE,EAAE,CAAC,IAAI,CAAC,EAAE,EAAE,CAAC,CAAC;IAC7D,CAAC;IAED,MAAM,UAAU,GAAG,IAAI,GAAG,EAA2B,CAAC;IACtD,KAAK,MAAM,EAAE,IAAI,gBAAgB,EAAE,CAAC;QAClC,UAAU,CAAC,GAAG,CAAC,YAAY,CAAC,EAAE,CAAC,MAAM,EAAE,EAAE,CAAC,IAAI,CAAC,EAAE,EAAE,CAAC,CAAC;IACvD,CAAC;IAED,MAAM,KAAK,GAA6B,EAAE,CAAC;IAC3C,MAAM,OAAO,GAA6B,EAAE,CAAC;IAC7C,MAAM,SAAS,GAAa,EAAE,CAAC;IAE/B,KAAK,MAAM,CAAC,GAAG,EAAE,EAAE,CAAC,IAAI,SAAS,EAAE,CAAC;QAClC,MAAM,OAAO,GAAG,UAAU,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;QACpC,IAAI,CAAC,OAAO,EAAE,CAAC;YACb,KAAK,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;QACjB,CAAC;aAAM,CAAC;YACN,MAAM,OAAO,GAAG,gBAAgB,CAAC,EAAE,EAAE,OAAO,CAAC,CAAC;YAC9C,IAAI,OAAO,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;gBACvB,OAAO,CAAC,IAAI,CAAC;oBACX,IAAI,EAAE,EAAE,CAAC,IAAI;oBACb,aAAa,EAAE,EAAE,CAAC,aAAa;oBAC/B,OAAO;iBACR,CAAC,CAAC;YACL,CAAC;iBAAM,CAAC;gBACN,SAAS,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;YACtB,CAAC;QACH,CAAC;IACH,CAAC;IAED,MAAM,OAAO,GAAsB,EAAE,CAAC;IACtC,KAAK,MAAM,CAAC,GAAG,EAAE,EAAE,CAAC,IAAI,UAAU,EAAE,CAAC;QACnC,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,GAAG,CAAC,EAAE,CAAC;YACxB,OAAO,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;QACnB,CAAC;IACH,CAAC;IAED,OAAO,EAAC,KAAK,EAAE,OAAO,EAAE,OAAO,EAAE,SAAS,EAAC,CAAC;AAC9C,CAAC;AAED,SAAS,YAAY,CAAC,aAAqB,EAAE,IAAY;IACvD,OAAO,GAAG,aAAa,CAAC,WAAW,EAAE,IAAI,IAAI,EAAE,CAAC;AAClD,CAAC;AAED,SAAS,gBAAgB,CACvB,QAAgC,EAChC,SAA0B;IAE1B,MAAM,OAAO,GAAa,EAAE,CAAC;IAE7B,yCAAyC;IACzC,IACE,QAAQ,CAAC,WAAW;QACpB,SAAS,CAAC,WAAW;QACrB,QAAQ,CAAC,WAAW,KAAK,SAAS,CAAC,WAAW,EAC9C,CAAC;QACD,OAAO,CAAC,IAAI,CAAC,qBAAqB,CAAC,CAAC;IACtC,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Amodal Labs, Inc.
|
|
4
|
+
* SPDX-License-Identifier: MIT
|
|
5
|
+
*/
|
|
6
|
+
/**
|
|
7
|
+
* Parsed GraphQL operation from an introspection result.
|
|
8
|
+
*/
|
|
9
|
+
export interface ParsedGraphQLOperation {
|
|
10
|
+
name: string;
|
|
11
|
+
operationType: 'query' | 'mutation' | 'subscription';
|
|
12
|
+
args: Array<{
|
|
13
|
+
name: string;
|
|
14
|
+
type: string;
|
|
15
|
+
required: boolean;
|
|
16
|
+
}>;
|
|
17
|
+
returnType: string;
|
|
18
|
+
description?: string;
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* Parse a GraphQL introspection result into a flat list of operations.
|
|
22
|
+
*/
|
|
23
|
+
export declare function parseGraphQLIntrospection(introspection: unknown): ParsedGraphQLOperation[];
|
|
24
|
+
/**
|
|
25
|
+
* Fetch an introspection result from a GraphQL endpoint and parse it.
|
|
26
|
+
*/
|
|
27
|
+
export declare function fetchAndParseGraphQLSchema(url: string, auth?: {
|
|
28
|
+
header: string;
|
|
29
|
+
value: string;
|
|
30
|
+
}): Promise<ParsedGraphQLOperation[]>;
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Amodal Labs, Inc.
|
|
4
|
+
* SPDX-License-Identifier: MIT
|
|
5
|
+
*/
|
|
6
|
+
/**
|
|
7
|
+
* Parse a GraphQL introspection result into a flat list of operations.
|
|
8
|
+
*/
|
|
9
|
+
export function parseGraphQLIntrospection(introspection) {
|
|
10
|
+
// eslint-disable-next-line @typescript-eslint/no-unsafe-type-assertion -- parsing unknown introspection shape
|
|
11
|
+
const schema = introspection;
|
|
12
|
+
const root = schema.__schema ?? schema.data?.__schema;
|
|
13
|
+
if (!root) {
|
|
14
|
+
return [];
|
|
15
|
+
}
|
|
16
|
+
const types = root.types ?? [];
|
|
17
|
+
const operations = [];
|
|
18
|
+
const rootTypeNames = new Map();
|
|
19
|
+
if (root.queryType?.name) {
|
|
20
|
+
rootTypeNames.set(root.queryType.name, 'query');
|
|
21
|
+
}
|
|
22
|
+
if (root.mutationType?.name) {
|
|
23
|
+
rootTypeNames.set(root.mutationType.name, 'mutation');
|
|
24
|
+
}
|
|
25
|
+
if (root.subscriptionType?.name) {
|
|
26
|
+
rootTypeNames.set(root.subscriptionType.name, 'subscription');
|
|
27
|
+
}
|
|
28
|
+
for (const type of types) {
|
|
29
|
+
if (!type.name)
|
|
30
|
+
continue;
|
|
31
|
+
const operationType = rootTypeNames.get(type.name);
|
|
32
|
+
if (!operationType)
|
|
33
|
+
continue;
|
|
34
|
+
for (const field of type.fields ?? []) {
|
|
35
|
+
if (!field.name)
|
|
36
|
+
continue;
|
|
37
|
+
// Skip internal fields
|
|
38
|
+
if (field.name.startsWith('__'))
|
|
39
|
+
continue;
|
|
40
|
+
operations.push({
|
|
41
|
+
name: field.name,
|
|
42
|
+
operationType,
|
|
43
|
+
args: (field.args ?? []).map((arg) => ({
|
|
44
|
+
name: arg.name ?? '',
|
|
45
|
+
type: formatTypeRef(arg.type),
|
|
46
|
+
required: isRequired(arg.type),
|
|
47
|
+
})),
|
|
48
|
+
returnType: formatTypeRef(field.type),
|
|
49
|
+
description: field.description ?? undefined,
|
|
50
|
+
});
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
return operations;
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* Format a type reference into a human-readable string.
|
|
57
|
+
*/
|
|
58
|
+
function formatTypeRef(ref) {
|
|
59
|
+
if (!ref)
|
|
60
|
+
return 'Unknown';
|
|
61
|
+
switch (ref.kind) {
|
|
62
|
+
case 'NON_NULL':
|
|
63
|
+
return `${formatTypeRef(ref.ofType)}!`;
|
|
64
|
+
case 'LIST':
|
|
65
|
+
return `[${formatTypeRef(ref.ofType)}]`;
|
|
66
|
+
case 'SCALAR':
|
|
67
|
+
case 'OBJECT':
|
|
68
|
+
case 'ENUM':
|
|
69
|
+
case 'INPUT_OBJECT':
|
|
70
|
+
case 'INTERFACE':
|
|
71
|
+
case 'UNION':
|
|
72
|
+
return ref.name ?? 'Unknown';
|
|
73
|
+
default:
|
|
74
|
+
return ref.name ?? 'Unknown';
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
/**
|
|
78
|
+
* Check if a type reference is non-null (required).
|
|
79
|
+
*/
|
|
80
|
+
function isRequired(ref) {
|
|
81
|
+
return ref?.kind === 'NON_NULL';
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* Fetch an introspection result from a GraphQL endpoint and parse it.
|
|
85
|
+
*/
|
|
86
|
+
export async function fetchAndParseGraphQLSchema(url, auth) {
|
|
87
|
+
const headers = {
|
|
88
|
+
'Content-Type': 'application/json',
|
|
89
|
+
};
|
|
90
|
+
if (auth) {
|
|
91
|
+
headers[auth.header] = auth.value;
|
|
92
|
+
}
|
|
93
|
+
const query = `{
|
|
94
|
+
__schema {
|
|
95
|
+
queryType { name }
|
|
96
|
+
mutationType { name }
|
|
97
|
+
subscriptionType { name }
|
|
98
|
+
types {
|
|
99
|
+
name
|
|
100
|
+
kind
|
|
101
|
+
description
|
|
102
|
+
fields {
|
|
103
|
+
name
|
|
104
|
+
description
|
|
105
|
+
args {
|
|
106
|
+
name
|
|
107
|
+
type { kind name ofType { kind name ofType { kind name ofType { kind name } } } }
|
|
108
|
+
}
|
|
109
|
+
type { kind name ofType { kind name ofType { kind name ofType { kind name } } } }
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
}`;
|
|
114
|
+
const response = await fetch(url, {
|
|
115
|
+
method: 'POST',
|
|
116
|
+
headers,
|
|
117
|
+
body: JSON.stringify({ query }),
|
|
118
|
+
});
|
|
119
|
+
if (!response.ok) {
|
|
120
|
+
throw new Error(`GraphQL introspection failed: HTTP ${response.status}`);
|
|
121
|
+
}
|
|
122
|
+
const data = await response.json();
|
|
123
|
+
return parseGraphQLIntrospection(data);
|
|
124
|
+
}
|
|
125
|
+
//# sourceMappingURL=graphql-parser.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"graphql-parser.js","sourceRoot":"","sources":["../../../src/repo/graphql-parser.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AA2DH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AG,EAAE,IAAI,KAAK,UAAU,CAAC;AAClC,CAAC;AAED;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,0BAA0B,CAC9C,GAAW,EACX,IAAsC;IAEtC,MAAM,OAAO,GAA2B;QACtC,cAAc,EAAE,kBAAkB;KACnC,CAAC;IACF,IAAI,IAAI,EAAE,CAAC;QACT,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC;IACpC,CAAC;IAED,MAAM,KAAK,GAAG;;;;;;;;;;;;;;;;;;;;IAoBZ,CAAC;IAEH,MAAM,QAAQ,GAAG,MAAM,KAAK,CAAC,GAAG,EAAE;QAChC,MAAM,EAAE,MAAM;QACd,OAAO;QACP,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,EAAC,KAAK,EAAC,CAAC;KAC9B,CAAC,CAAC;IAEH,IAAI,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC;QACjB,MAAM,IAAI,KAAK,CAAC,sCAAsC,QAAQ,CAAC,MAAM,EAAE,CAAC,CAAC;IAC3E,CAAC;IAED,MAAM,IAAI,GAAY,MAAM,QAAQ,CAAC,IAAI,EAAE,CAAC;IAC5C,OAAO,yBAAyB,CAAC,IAAI,CAAC,CAAC;AACzC,CAAC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Amodal Labs, Inc.
|
|
4
|
+
* SPDX-License-Identifier: MIT
|
|
5
|
+
*/
|
|
6
|
+
import type { SurfaceEndpoint } from './connection-types.js';
|
|
7
|
+
/**
|
|
8
|
+
* Parse a GraphQL surface.md content into SurfaceEndpoint[].
|
|
9
|
+
*
|
|
10
|
+
* GraphQL operations use ### QUERY, ### MUTATION, ### SUBSCRIPTION headings
|
|
11
|
+
* instead of HTTP method + path headings.
|
|
12
|
+
*
|
|
13
|
+
* The method field stores the operation type (QUERY, MUTATION, SUBSCRIPTION).
|
|
14
|
+
* The path field stores the operation name.
|
|
15
|
+
*/
|
|
16
|
+
export declare function parseGraphQLSurface(content: string): SurfaceEndpoint[];
|
|
17
|
+
/**
|
|
18
|
+
* Detect whether content is a GraphQL surface (uses QUERY/MUTATION/SUBSCRIPTION headings).
|
|
19
|
+
*/
|
|
20
|
+
export declare function isGraphQLSurface(content: string): boolean;
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Amodal Labs, Inc.
|
|
4
|
+
* SPDX-License-Identifier: MIT
|
|
5
|
+
*/
|
|
6
|
+
const GRAPHQL_HEADING_RE = /^###\s+(QUERY|MUTATION|SUBSCRIPTION)\s+(\S+)/;
|
|
7
|
+
const INCLUDED_HEADING_RE = /^##\s+Included/i;
|
|
8
|
+
const EXCLUDED_HEADING_RE = /^##\s+Excluded/i;
|
|
9
|
+
/**
|
|
10
|
+
* Parse a GraphQL surface.md content into SurfaceEndpoint[].
|
|
11
|
+
*
|
|
12
|
+
* GraphQL operations use ### QUERY, ### MUTATION, ### SUBSCRIPTION headings
|
|
13
|
+
* instead of HTTP method + path headings.
|
|
14
|
+
*
|
|
15
|
+
* The method field stores the operation type (QUERY, MUTATION, SUBSCRIPTION).
|
|
16
|
+
* The path field stores the operation name.
|
|
17
|
+
*/
|
|
18
|
+
export function parseGraphQLSurface(content) {
|
|
19
|
+
const lines = content.split('\n');
|
|
20
|
+
const endpoints = [];
|
|
21
|
+
let state = 'scanning';
|
|
22
|
+
let hasIncludedSection = false;
|
|
23
|
+
let currentEndpoint = null;
|
|
24
|
+
const descriptionLines = [];
|
|
25
|
+
function flushEndpoint() {
|
|
26
|
+
if (currentEndpoint) {
|
|
27
|
+
currentEndpoint.description = descriptionLines.join('\n').trim();
|
|
28
|
+
endpoints.push(currentEndpoint);
|
|
29
|
+
descriptionLines.length = 0;
|
|
30
|
+
currentEndpoint = null;
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
for (const line of lines) {
|
|
34
|
+
if (INCLUDED_HEADING_RE.test(line)) {
|
|
35
|
+
flushEndpoint();
|
|
36
|
+
state = 'included';
|
|
37
|
+
hasIncludedSection = true;
|
|
38
|
+
continue;
|
|
39
|
+
}
|
|
40
|
+
if (EXCLUDED_HEADING_RE.test(line)) {
|
|
41
|
+
flushEndpoint();
|
|
42
|
+
state = 'excluded';
|
|
43
|
+
continue;
|
|
44
|
+
}
|
|
45
|
+
const gqlMatch = GRAPHQL_HEADING_RE.exec(line);
|
|
46
|
+
if (gqlMatch) {
|
|
47
|
+
flushEndpoint();
|
|
48
|
+
const included = state !== 'excluded';
|
|
49
|
+
currentEndpoint = {
|
|
50
|
+
method: gqlMatch[1],
|
|
51
|
+
path: gqlMatch[2],
|
|
52
|
+
description: '',
|
|
53
|
+
included,
|
|
54
|
+
};
|
|
55
|
+
continue;
|
|
56
|
+
}
|
|
57
|
+
if (currentEndpoint) {
|
|
58
|
+
descriptionLines.push(line);
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
flushEndpoint();
|
|
62
|
+
// Same convention as REST: if no explicit Included section, all are included
|
|
63
|
+
if (!hasIncludedSection) {
|
|
64
|
+
// All endpoints already default to included
|
|
65
|
+
}
|
|
66
|
+
return endpoints;
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* Detect whether content is a GraphQL surface (uses QUERY/MUTATION/SUBSCRIPTION headings).
|
|
70
|
+
*/
|
|
71
|
+
export function isGraphQLSurface(content) {
|
|
72
|
+
return GRAPHQL_HEADING_RE.test(content);
|
|
73
|
+
}
|
|
74
|
+
//# sourceMappingURL=graphql-surface-parser.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"graphql-surface-parser.js","sourceRoot":"","sources":["../../../src/repo/graphql-surface-parser.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAMH,MAAM,kBAAkB,GAAG,8CAA8C,CAAC;AAC1E,MAAM,mBAAmB,GAAG,iBAAiB,CAAC;AAC9C,MAAM,mB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IAAI,EAAE,QAAQ,CAAC,CAAC,CAAC;gBACjB,WAAW,EAAE,EAAE;gBACf,QAAQ;aACT,CAAC;YACF,SAAS;QACX,CAAC;QAED,IAAI,eAAe,EAAE,CAAC;YACpB,gBAAgB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAC9B,CAAC;IACH,CAAC;IAED,aAAa,EAAE,CAAC;IAEhB,6EAA6E;IAC7E,IAAI,CAAC,kBAAkB,EAAE,CAAC;QACxB,4CAA4C;IAC9C,CAAC;IAED,OAAO,SAAS,CAAC;AACnB,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,gBAAgB,CAAC,OAAe;IAC9C,OAAO,kBAAkB,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;AAC1C,CAAC"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Amodal Labs, Inc.
|
|
4
|
+
* SPDX-License-Identifier: MIT
|
|
5
|
+
*/
|
|
6
|
+
export * from './repo-types.js';
|
|
7
|
+
export * from './connection-types.js';
|
|
8
|
+
export { AmodalConfigSchema, ModelConfigSchema, parseConfigJson, resolveEnvValue, resolveEnvValues, } from './config-schema.js';
|
|
9
|
+
export type { AmodalConfig, ModelConfig } from './config-schema.js';
|
|
10
|
+
export { AccessConfigSchema, AlternativeLookupSchema, ConnectionSpecSchema, EndpointAccessSchema, FieldRestrictionSchema, ScopingRuleSchema, ThresholdSchema, } from './connection-schemas.js';
|
|
11
|
+
export type { AccessConfig, AlternativeLookup, ConnectionSpec, EndpointAccess, FieldRestriction, ScopingRule, Threshold, } from './connection-schemas.js';
|
|
12
|
+
export { parseAgent, parseConfig, parseAccessJson, parseSpecJson, parseConnection, parseSkill, parseKnowledge, parseAutomation, parseEval, } from './parsers.js';
|
|
13
|
+
export { parseSurface } from './surface-parser.js';
|
|
14
|
+
export type { StoreFieldType, StoreFieldDefinition, StoreEntityDefinition, StoreTtlConfig, StoreFailureConfig, StoreHistoryConfig, LoadedStore, } from './store-types.js';
|
|
15
|
+
export { StoreJsonSchema, StoreFieldDefinitionSchema, StoreEntitySchema, StoreTtlConfigSchema, StoreFailureConfigSchema, StoreHistoryConfigSchema, STORE_NAME_REGEX, } from './store-schemas.js';
|
|
16
|
+
export type { StoreJson } from './store-schemas.js';
|
|
17
|
+
export { loadStores, parseStoreJson } from './store-loader.js';
|
|
18
|
+
export { storeToJsonSchema, storeToToolName, findStoreByToolName, fieldToJsonSchema } from './store-tool-schema.js';
|
|
19
|
+
export { ToolJsonSchema, TOOL_NAME_REGEX, defineToolHandler } from './tool-types.js';
|
|
20
|
+
export type { ToolJson, LoadedTool, CustomToolContext, CustomToolExecutor, CustomShellExecutor, ToolHandlerDefinition } from './tool-types.js';
|
|
21
|
+
export { loadTools, isToolHandlerDefinition } from './tool-loader.js';
|
|
22
|
+
export { loadRepoFromDisk } from './local-reader.js';
|
|
23
|
+
export { loadRepoFromPlatform } from './platform-reader.js';
|
|
24
|
+
export { loadRepo } from './repo-loader.js';
|
|
25
|
+
export { parseOpenAPISpec, fetchAndParseSpec } from './openapi-parser.js';
|
|
26
|
+
export type { ParsedEndpoint, ParsedParameter } from './openapi-parser.js';
|
|
27
|
+
export { detectDrift } from './drift-detector.js';
|
|
28
|
+
export type { DriftResult, EndpointChange } from './drift-detector.js';
|
|
29
|
+
export { buildSyncPlan } from './spec-syncer.js';
|
|
30
|
+
export type { SyncPlan } from './spec-syncer.js';
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Amodal Labs, Inc.
|
|
4
|
+
* SPDX-License-Identifier: MIT
|
|
5
|
+
*/
|
|
6
|
+
// Types
|
|
7
|
+
export * from './repo-types.js';
|
|
8
|
+
export * from './connection-types.js';
|
|
9
|
+
// Schemas
|
|
10
|
+
export { AmodalConfigSchema, ModelConfigSchema, parseConfigJson, resolveEnvValue, resolveEnvValues, } from './config-schema.js';
|
|
11
|
+
export { AccessConfigSchema, AlternativeLookupSchema, ConnectionSpecSchema, EndpointAccessSchema, FieldRestrictionSchema, ScopingRuleSchema, ThresholdSchema, } from './connection-schemas.js';
|
|
12
|
+
// Parsers
|
|
13
|
+
export { parseAgent, parseConfig, parseAccessJson, parseSpecJson, parseConnection, parseSkill, parseKnowledge, parseAutomation, parseEval, } from './parsers.js';
|
|
14
|
+
export { parseSurface } from './surface-parser.js';
|
|
15
|
+
export { StoreJsonSchema, StoreFieldDefinitionSchema, StoreEntitySchema, StoreTtlConfigSchema, StoreFailureConfigSchema, StoreHistoryConfigSchema, STORE_NAME_REGEX, } from './store-schemas.js';
|
|
16
|
+
export { loadStores, parseStoreJson } from './store-loader.js';
|
|
17
|
+
export { storeToJsonSchema, storeToToolName, findStoreByToolName, fieldToJsonSchema } from './store-tool-schema.js';
|
|
18
|
+
// Tool types
|
|
19
|
+
export { ToolJsonSchema, TOOL_NAME_REGEX, defineToolHandler } from './tool-types.js';
|
|
20
|
+
export { loadTools, isToolHandlerDefinition } from './tool-loader.js';
|
|
21
|
+
// Readers
|
|
22
|
+
export { loadRepoFromDisk } from './local-reader.js';
|
|
23
|
+
export { loadRepoFromPlatform } from './platform-reader.js';
|
|
24
|
+
export { loadRepo } from './repo-loader.js';
|
|
25
|
+
// Sync utilities
|
|
26
|
+
export { parseOpenAPISpec, fetchAndParseSpec } from './openapi-parser.js';
|
|
27
|
+
export { detectDrift } from './drift-detector.js';
|
|
28
|
+
export { buildSyncPlan } from './spec-syncer.js';
|
|
29
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/repo/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,QAAQ;AACR,cAAc,iBAAiB,CAAC;AAChC,cAAc,uBAAuB,CAAC;AAEtC,UAAU;AACV,OAAO,EACL,kBAAkB,EAClB,iBAAiB,EACjB,eAAe,EACf,eAAe,EACf,gB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|
|
3
|
+
* Copyright 2026 Amodal Labs, Inc.
|
|
4
|
+
* SPDX-License-Identifier: MIT
|
|
5
|
+
*/
|
|
6
|
+
import type { AmodalRepo } from './repo-types.js';
|
|
7
|
+
/**
|
|
8
|
+
* Load the full amodal repo from disk.
|
|
9
|
+
*/
|
|
10
|
+
export declare function loadRepoFromDisk(repoPath: string): Promise<AmodalRepo>;
|