thinkwork-cli 0.13.1 → 1.0.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/README.md +3 -14
- package/dist/{api-client-4DZ266J5.js → api-client-4P4JZOBX.js} +3 -1
- package/dist/bowser-6Z6JFAIR.js +2822 -0
- package/dist/{chunk-Y2WHJECR.js → chunk-4OMDWYZQ.js} +5 -44
- package/dist/chunk-AD2NIWB5.js +6516 -0
- package/dist/chunk-DV3MRBR5.js +43 -0
- package/dist/chunk-EI5ZX7CN.js +522 -0
- package/dist/chunk-EUJ7X6YD.js +126 -0
- package/dist/chunk-GG5WKBOX.js +436 -0
- package/dist/chunk-I64EZSU5.js +358 -0
- package/dist/chunk-KMIJ5KGT.js +128 -0
- package/dist/chunk-MWQ7RO76.js +137 -0
- package/dist/chunk-OCPHU34C.js +996 -0
- package/dist/chunk-OLUQ4U2Z.js +1728 -0
- package/dist/chunk-XYM7PE2A.js +2264 -0
- package/dist/chunk-YQCYD6NE.js +3299 -0
- package/dist/cli.js +49156 -31257
- package/dist/commands/enterprise/templates/deploy-repo/scripts/apply-release.mjs +0 -1
- package/dist/commands/enterprise/templates/deploy-repo/scripts/smoke.mjs +0 -1
- package/dist/commands/enterprise/templates/deploy-repo/terraform/main.tf +0 -14
- package/dist/dist-es-2OTNTL4N.js +315 -0
- package/dist/dist-es-2XVAH4BQ.js +14726 -0
- package/dist/dist-es-3DPDUJAH.js +2000 -0
- package/dist/dist-es-BNZTBBVC.js +176 -0
- package/dist/dist-es-CD2RBDAC.js +88 -0
- package/dist/dist-es-I4FW57PS.js +88 -0
- package/dist/dist-es-KL7Y5NB2.js +377 -0
- package/dist/dist-es-KVFWJNDY.js +318 -0
- package/dist/dist-es-PS73DWNL.js +70 -0
- package/dist/dist-es-S3NZQFGT.js +170 -0
- package/dist/dist-es-SGCA4P32.js +48 -0
- package/dist/dist-es-WBM6J4RA.js +70 -0
- package/dist/dist-es-ZGVADYIF.js +485 -0
- package/dist/dist-es-ZKC2QKD2.js +377 -0
- package/dist/drizzle/0076_scheduled_jobs_marco_backfill.sql +2 -1
- package/dist/drizzle/0079_seed_tenant_customize_catalog.sql +1 -0
- package/dist/drizzle/0090_brain_schema_extraction.sql +10 -0
- package/dist/drizzle/0132_drop_computer_tables.sql +3 -0
- package/dist/drizzle/0160_compliance_event_types_plugins.sql +2 -0
- package/dist/drizzle/0214_think137_drop_judge_evidence_roi.sql +1 -0
- package/dist/drizzle/0216_drop_agent_loop_versions_goal_worker_policy.sql +1 -0
- package/dist/drizzle/0227_analyst_reader_role.sql +17 -20
- package/dist/drizzle/0230_analyst_rls.sql +28 -36
- package/dist/drizzle/0250_kg_schema_extraction.sql +27 -0
- package/dist/drizzle/0251_brain_stragglers.sql +21 -0
- package/dist/drizzle/0253_drop_brain_substrate.sql +2 -0
- package/dist/drizzle/0257_agents_runtime_allow_harness.sql +24 -0
- package/dist/drizzle/0261_native_auth_control_plane.sql +332 -0
- package/dist/drizzle/0262_auth_subscription_tickets.sql +59 -0
- package/dist/drizzle/0263_agentcore_runtime_identifier.sql +69 -0
- package/dist/drizzle/0263_drop_workos_auth_runtime.sql +236 -0
- package/dist/drizzle/0264_auth_enrollment_attempt_limits.sql +15 -0
- package/dist/drizzle/0265_eval_runs_requester_identity.sql +28 -0
- package/dist/drizzle/0265_require_fully_valid_auth_publication.sql +27 -0
- package/dist/drizzle/0266_auth_identity_recovery_grants.sql +9 -0
- package/dist/drizzle/0266_eval_profiles_runtime_type.sql +12 -0
- package/dist/drizzle/0267_ontology_candidate_rejections.sql +53 -0
- package/dist/drizzle/0268_identity_crosswalk_routing.sql +182 -0
- package/dist/drizzle/0269_ontology_system_map.sql +31 -0
- package/dist/drizzle/0270_tool_execution_ledger.sql +115 -0
- package/dist/drizzle/0271_ontology_twin_declarations.sql +47 -0
- package/dist/drizzle/0272_identity_graph_projection_cursor.sql +23 -0
- package/dist/drizzle/0273_twin_materialization_suggestions.sql +29 -0
- package/dist/drizzle/0274_tenant_mcp_twin_keys.sql +59 -0
- package/dist/drizzle/0275_identity_bulk_rebuild_fence.sql +30 -0
- package/dist/drizzle/0276_tool_execution_ledger_allow_cascade_delete.sql +18 -0
- package/dist/drizzle/0277_knowledge_base_sources.sql +107 -0
- package/dist/drizzle/0278_kb_page_transcription.sql +55 -0
- package/dist/drizzle/0279_mcp_servers_off_plugin_provenance.sql +93 -0
- package/dist/drizzle/0280_work_item_external_refs_drop_plane_provider.sql +46 -0
- package/dist/drizzle/0281_tenant_mcp_twin_keys_expiry_suffix.sql +9 -0
- package/dist/drizzle/0282_tenant_mcp_twin_keys_grants.sql +24 -0
- package/dist/drizzle/0283_agents_agentcore_runtime_dispatch.sql +13 -0
- package/dist/drizzle/0284_user_brain_claims.sql +69 -0
- package/dist/drizzle/0285_tenant_mcp_twin_keys_trusted_subsystem.sql +30 -0
- package/dist/drizzle/0286_brain_analytics_key.sql +26 -0
- package/dist/drizzle/0287_brain_subject.sql +25 -0
- package/dist/drizzle/0288_multi_lane_identities.sql +25 -0
- package/dist/event-streams-7JNLJEEL.js +894 -0
- package/dist/event-streams-KDF5RWR6.js +1515 -0
- package/dist/loadSso-ETCXTR4I.js +576 -0
- package/dist/loadSso-UBD7KUHE.js +583 -0
- package/dist/plugins/README.md +2 -2
- package/dist/plugins/catalog/package.json +1 -5
- package/dist/plugins/catalog/src/__tests__/build-catalog.test.ts +6 -4
- package/dist/plugins/catalog/src/__tests__/catalog.test.ts +21 -21
- package/dist/plugins/catalog/src/__tests__/contracts.test.ts +102 -94
- package/dist/plugins/catalog/src/__tests__/plugin-package.test.ts +7 -8
- package/dist/plugins/catalog/src/__tests__/plugin-registry.test.ts +0 -20
- package/dist/plugins/catalog/src/contracts.ts +17 -179
- package/dist/plugins/catalog/src/registry/generated-first-party.ts +0 -24
- package/dist/plugins/n8n/test/integrated-app-contract.test.ts +1 -1
- package/dist/plugins/twenty/package.json +2 -1
- package/dist/plugins/twenty/scripts/LAMBDA_DEPLOY.md +114 -0
- package/dist/plugins/twenty/scripts/build-lambda.sh +29 -0
- package/dist/plugins/twenty/scripts/configure-product-views.ts +195 -0
- package/dist/plugins/twenty/scripts/lambda-handler.ts +49 -0
- package/dist/plugins/twenty/scripts/lib/__tests__/load-attachments.test.ts +38 -0
- package/dist/plugins/twenty/scripts/lib/__tests__/load-records.test.ts +145 -2
- package/dist/plugins/twenty/scripts/lib/__tests__/mappers.test.ts +397 -151
- package/dist/plugins/twenty/scripts/lib/__tests__/members-ensure.test.ts +28 -129
- package/dist/plugins/twenty/scripts/lib/__tests__/provision-members-db.test.ts +10 -0
- package/dist/plugins/twenty/scripts/lib/__tests__/schema-ensure.test.ts +13 -8
- package/dist/plugins/twenty/scripts/lib/lastmile-reader.ts +222 -2
- package/dist/plugins/twenty/scripts/lib/load-attachments.ts +29 -0
- package/dist/plugins/twenty/scripts/lib/load-records.ts +160 -43
- package/dist/plugins/twenty/scripts/lib/mappers.ts +368 -152
- package/dist/plugins/twenty/scripts/lib/members-ensure.ts +43 -268
- package/dist/plugins/twenty/scripts/lib/provision-members-db.ts +57 -0
- package/dist/plugins/twenty/scripts/lib/schema-ensure.ts +136 -31
- package/dist/plugins/twenty/scripts/migrate-lastmile.ts +254 -152
- package/dist/plugins/twenty/scripts/provision-twenty-members.ts +44 -1
- package/dist/plugins/twenty/scripts/purge-lastmile-import.ts +178 -0
- package/dist/plugins/twenty/scripts/restructure-products.ts +312 -0
- package/dist/plugins/twenty/scripts/retag-stage-values.ts +362 -0
- package/dist/plugins/twenty/test/manifest.test.ts +2 -4
- package/dist/scripts/post-deploy.sh +79 -1
- package/dist/signin-5QZNRSOO.js +821 -0
- package/dist/sso-oidc-XK673P54.js +837 -0
- package/dist/sts-OXI2UALF.js +1113 -0
- package/dist/sts-SQW4NBK3.js +1117 -0
- package/dist/terraform/examples/greenfield/main.tf +391 -176
- package/dist/terraform/examples/greenfield/terraform.tfvars.example +26 -8
- package/dist/terraform/modules/app/agentcore-admin/main.tf +47 -0
- package/dist/terraform/modules/app/agentcore-code-interpreter/README.md +39 -47
- package/dist/terraform/modules/app/agentcore-code-interpreter/main.tf +13 -66
- package/dist/terraform/modules/app/agentcore-identity/main.tf +253 -0
- package/dist/terraform/modules/app/agentcore-identity/outputs.tf +51 -0
- package/dist/terraform/modules/app/agentcore-identity/scripts/bootstrap_twenty_oauth_client.sh +239 -0
- package/dist/terraform/modules/app/agentcore-identity/scripts/delete_identity.sh +22 -0
- package/dist/terraform/modules/app/agentcore-identity/scripts/delete_twenty_identity.sh +16 -0
- package/dist/terraform/modules/app/agentcore-identity/scripts/delete_workload_identity.sh +19 -0
- package/dist/terraform/modules/app/agentcore-identity/scripts/ensure_workload_identity.sh +29 -0
- package/dist/terraform/modules/app/agentcore-identity/scripts/read_identity.sh +55 -0
- package/dist/terraform/modules/app/agentcore-identity/scripts/reconcile_identity.sh +73 -0
- package/dist/terraform/modules/app/agentcore-identity/scripts/reconcile_twenty_identity.sh +45 -0
- package/dist/terraform/modules/app/agentcore-identity/scripts/reconcile_twenty_provider.mjs +123 -0
- package/dist/terraform/modules/app/agentcore-identity/tests/tainted-marker/after.tf +15 -0
- package/dist/terraform/modules/app/agentcore-identity/tests/tainted-marker/before.tf +7 -0
- package/dist/terraform/modules/app/agentcore-identity/tests/tainted-marker/identity-after.tf +8 -0
- package/dist/terraform/modules/app/agentcore-identity/tests/tainted-marker/identity-before.tf +9 -0
- package/dist/terraform/modules/app/agentcore-identity/tests/tainted-marker/thinkwork-after.tf +3 -0
- package/dist/terraform/modules/app/agentcore-identity/tests/tainted-marker/thinkwork-before.tf +3 -0
- package/dist/terraform/modules/app/agentcore-identity/variables.tf +60 -0
- package/dist/terraform/modules/app/agentcore-memory/README.md +46 -9
- package/dist/terraform/modules/app/agentcore-memory/main.tf +27 -10
- package/dist/terraform/modules/app/agentcore-memory/scripts/create_or_find_memory.sh +156 -24
- package/dist/terraform/modules/app/agentcore-pi/README.md +1 -3
- package/dist/terraform/modules/app/agentcore-pi/main.tf +42 -52
- package/dist/terraform/modules/app/agentcore-pi/outputs.tf +3 -3
- package/dist/terraform/modules/app/agentcore-pi/scripts/reconcile_pi_runtime.mjs +175 -0
- package/dist/terraform/modules/app/agentcore-pi/variables.tf +35 -28
- package/dist/terraform/modules/app/agentcore-platform/main.tf +68 -0
- package/dist/terraform/modules/app/agentcore-runtime/main.tf +4 -20
- package/dist/terraform/modules/app/appsync-subscriptions/main.tf +127 -21
- package/dist/terraform/modules/app/appsync-subscriptions/outputs.tf +0 -6
- package/dist/terraform/modules/app/appsync-subscriptions/variables.tf +5 -0
- package/dist/terraform/modules/app/capability-broker/main.tf +2 -2
- package/dist/terraform/modules/app/capability-broker/variables.tf +11 -0
- package/dist/terraform/modules/app/deployment-control-plane/README.md +264 -0
- package/dist/terraform/modules/app/deployment-control-plane/buildspec.yml +4 -1
- package/dist/terraform/modules/app/deployment-control-plane/main.tf +94 -0
- package/dist/terraform/modules/app/deployment-control-plane/outputs.tf +5 -0
- package/dist/terraform/modules/app/deployment-control-plane/runner.py +3689 -233
- package/dist/terraform/modules/app/deployment-control-plane/test_runner_bundle.py +2579 -140
- package/dist/terraform/modules/app/deployment-control-plane/variables.tf +33 -0
- package/dist/terraform/modules/app/lambda-api/auth-state.tf +72 -0
- package/dist/terraform/modules/app/lambda-api/chat-latency-observability.tf +466 -0
- package/dist/terraform/modules/app/lambda-api/dispatch-dlq.tf +55 -0
- package/dist/terraform/modules/app/lambda-api/handlers.tf +531 -619
- package/dist/terraform/modules/app/lambda-api/iam-grouped.tf +350 -241
- package/dist/terraform/modules/app/lambda-api/main.tf +75 -13
- package/dist/terraform/modules/app/lambda-api/memory-alarms.tf +3 -28
- package/dist/terraform/modules/app/lambda-api/oauth-secrets.tf +1 -2
- package/dist/terraform/modules/app/lambda-api/outputs.tf +17 -10
- package/dist/terraform/modules/app/lambda-api/runtime-config.tf +3 -21
- package/dist/terraform/modules/app/lambda-api/turn-assertion.tf +45 -0
- package/dist/terraform/modules/app/lambda-api/variables.tf +307 -121
- package/dist/{plugins/n8n/terraform → terraform/modules/app}/n8n/README.md +1 -1
- package/dist/{plugins/n8n/terraform → terraform/modules/app}/n8n/main.tf +18 -18
- package/dist/terraform/modules/app/sandbox-log-scrubber/README.md +11 -10
- package/dist/terraform/modules/app/sandbox-log-scrubber/main.tf +5 -5
- package/dist/terraform/modules/app/static-site/main.tf +1 -1
- package/dist/terraform/modules/app/www-dns/main.tf +9 -27
- package/dist/terraform/modules/app/www-dns/variables.tf +4 -10
- package/dist/terraform/modules/data/aurora-postgres/README.md +34 -0
- package/dist/terraform/modules/data/aurora-postgres/alarms.tf +82 -0
- package/dist/terraform/modules/data/aurora-postgres/main.tf +27 -57
- package/dist/terraform/modules/data/aurora-postgres/outputs.tf +0 -9
- package/dist/terraform/modules/data/aurora-postgres/variables.tf +41 -0
- package/dist/terraform/modules/data/s3-buckets/main.tf +5 -6
- package/dist/terraform/modules/foundation/cognito/main.tf +367 -72
- package/dist/terraform/modules/foundation/cognito/outputs.tf +47 -0
- package/dist/terraform/modules/foundation/cognito/variables.tf +131 -9
- package/dist/terraform/modules/thinkwork/README.md +5 -1
- package/dist/terraform/modules/thinkwork/main.tf +459 -234
- package/dist/terraform/modules/thinkwork/outputs.tf +44 -62
- package/dist/terraform/modules/thinkwork/variables.tf +353 -89
- package/dist/terraform/schema.graphql +69 -36
- package/dist/workspace-defaults/files/INSTRUCTIONS.md +9 -11
- package/dist/workspace-defaults/files/MEMORY_GUIDE.md +38 -35
- package/dist/workspace-defaults/files/ROUTER.md +1 -1
- package/dist/workspace-defaults/files/TOOLS.md +9 -39
- package/dist/workspace-defaults/files/USER.md +1 -0
- package/dist/workspace-defaults/files/agents/analyst/INSTRUCTIONS.md +6 -3
- package/dist/workspace-defaults/files/catalog-skills/brain-brief-builder/SKILL.md +165 -0
- package/dist/workspace-defaults/files/catalog-skills/n8n-workflow-operator/SKILL.md +75 -0
- package/dist/workspace-defaults/files/catalog-skills/n8n-workflow-operator/references/mcp-tooling.md +40 -0
- package/dist/workspace-defaults/files/catalog-skills/n8n-workflow-operator/references/validation-and-handoff.md +40 -0
- package/dist/workspace-defaults/files/catalog-skills/n8n-workflow-operator/references/workflow-authoring.md +46 -0
- package/dist/workspace-defaults/files/skills/artifact-builder/references/crm-dashboard.md +1 -1
- package/dist/workspace-defaults/files/skills/document-composer/SKILL.md +22 -3
- package/package.json +3 -2
- package/dist/drizzle/0261_thread_turns_origin_turn_index.sql +0 -11
- package/dist/plugins/company-data/README.md +0 -49
- package/dist/plugins/company-data/package.json +0 -21
- package/dist/plugins/company-data/src/index.ts +0 -30
- package/dist/plugins/company-data/src/manifest.ts +0 -26
- package/dist/plugins/company-data/test/manifest.test.ts +0 -116
- package/dist/plugins/company-data/tsconfig.json +0 -8
- package/dist/plugins/company-etl/README.md +0 -46
- package/dist/plugins/company-etl/package.json +0 -21
- package/dist/plugins/company-etl/src/index.ts +0 -29
- package/dist/plugins/company-etl/src/manifest.ts +0 -26
- package/dist/plugins/company-etl/test/manifest.test.ts +0 -108
- package/dist/plugins/company-etl/tsconfig.json +0 -8
- package/dist/plugins/lastmile/README.md +0 -50
- package/dist/plugins/lastmile/package.json +0 -23
- package/dist/plugins/lastmile/smoke/lastmile-plugin-smoke.mjs +0 -661
- package/dist/plugins/lastmile/src/api/tasks-adapter.ts +0 -572
- package/dist/plugins/lastmile/src/discovery.fixture.ts +0 -64
- package/dist/plugins/lastmile/src/index.ts +0 -46
- package/dist/plugins/lastmile/src/manifest.ts +0 -139
- package/dist/plugins/lastmile/test/api/tasks-adapter.test.ts +0 -266
- package/dist/plugins/lastmile/test/discovery.test.ts +0 -88
- package/dist/plugins/lastmile/tsconfig.json +0 -8
- package/dist/plugins/n8n/smoke/n8n-managed-app-smoke.mjs +0 -409
- package/dist/plugins/twenty/smoke/twenty-managed-app-smoke.mjs +0 -359
- package/dist/plugins/workos-auth/package.json +0 -22
- package/dist/plugins/workos-auth/src/index.ts +0 -30
- package/dist/plugins/workos-auth/src/manifest.ts +0 -40
- package/dist/plugins/workos-auth/src/provider-contract.ts +0 -39
- package/dist/plugins/workos-auth/test/manifest.test.ts +0 -94
- package/dist/plugins/workos-auth/tsconfig.json +0 -8
- package/dist/terraform/modules/app/agentcore-code-interpreter/Dockerfile.sandbox-base +0 -61
- package/dist/terraform/modules/app/agentcore-code-interpreter/sandbox/sitecustomize.py +0 -227
- package/dist/terraform/modules/app/agentcore-code-interpreter/sandbox/test_sitecustomize.py +0 -277
- package/dist/terraform/modules/app/agentcore-code-interpreter/scripts/build_and_push_sandbox_base.sh +0 -70
- package/dist/terraform/modules/app/agentcore-harness/main.tf +0 -101
- package/dist/terraform/modules/app/agentcore-harness/outputs.tf +0 -9
- package/dist/terraform/modules/app/agentcore-harness/variables.tf +0 -25
- package/dist/terraform/modules/app/hindsight-memory/README.md +0 -89
- package/dist/terraform/modules/app/hindsight-memory/main.tf +0 -411
- package/dist/terraform/modules/data/bedrock-knowledge-base/main.tf +0 -102
- /package/dist/{plugins/n8n/terraform → terraform/modules/app}/n8n/outputs.tf +0 -0
- /package/dist/{plugins/n8n/terraform → terraform/modules/app}/n8n/scripts/sync-database.py +0 -0
- /package/dist/{plugins/n8n/terraform → terraform/modules/app}/n8n/scripts/test_sync_database.py +0 -0
- /package/dist/{plugins/n8n/terraform → terraform/modules/app}/n8n/variables.tf +0 -0
- /package/dist/{plugins/twenty/terraform → terraform/modules/app}/twenty/README.md +0 -0
- /package/dist/{plugins/twenty/terraform → terraform/modules/app}/twenty/main.tf +0 -0
- /package/dist/{plugins/twenty/terraform → terraform/modules/app}/twenty/outputs.tf +0 -0
- /package/dist/{plugins/twenty/terraform → terraform/modules/app}/twenty/variables.tf +0 -0
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: brain-brief-builder
|
|
3
|
+
description: Draft a new v2 Brain brief from a conversation. Use when someone asks to create, build, or set up a new Brain brief, report template, or recurring data brief from scratch. Interviews the operator, drafts the template through the Brain's capture endpoints, and hands back a builder link for review.
|
|
4
|
+
license: Apache-2.0
|
|
5
|
+
compatibility: The tenant's provisioned Company Brain connector with the Brief Builder v2 tools on its surface.
|
|
6
|
+
metadata:
|
|
7
|
+
skill-format: agentskills
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# Brain Brief Builder
|
|
11
|
+
|
|
12
|
+
Turn a conversation into a draft v2 Brain brief: a short interview, one
|
|
13
|
+
template-create call, a rule-capture pass per data section, and a link into
|
|
14
|
+
the Brain console builder where the operator reviews, tweaks, and saves.
|
|
15
|
+
Zero-to-one creation lives here — there is no console entry point for
|
|
16
|
+
drafting a brief with the agent, and this skill never suggests one.
|
|
17
|
+
|
|
18
|
+
## First Move
|
|
19
|
+
|
|
20
|
+
1. Use this skill when someone asks to create a new Brain brief from
|
|
21
|
+
scratch. Running an existing brief is `brain_brief_launch`, not this
|
|
22
|
+
skill; a one-off saved answer is `brain_report_create`.
|
|
23
|
+
2. Use the Brief Builder tools on the Company Brain connector:
|
|
24
|
+
`brain_brief_template_create`, `brain_brief_rule_propose`,
|
|
25
|
+
`brain_brief_rule_propose_result`, `brain_brief_rule_preview`,
|
|
26
|
+
`brain_brief_rule_accept`. Trust the live tool descriptions and
|
|
27
|
+
argument schemas over this skill if they disagree, and report the
|
|
28
|
+
drift in your handoff.
|
|
29
|
+
3. If those tools are missing, report that the tenant's Company Brain
|
|
30
|
+
connector does not yet expose the Brief Builder surface and stop —
|
|
31
|
+
do not improvise a brief through other tools.
|
|
32
|
+
|
|
33
|
+
## Interview
|
|
34
|
+
|
|
35
|
+
Keep it short — a handful of questions, batched where natural. You need:
|
|
36
|
+
|
|
37
|
+
1. **Coverage and audience.** What should the brief cover, and who reads
|
|
38
|
+
it? This becomes the template name and the document instructions.
|
|
39
|
+
2. **Sections.** Which sections, in order? For each: a fixed title, a
|
|
40
|
+
section type from the closed vocabulary — `stat`, `table`, `chart`,
|
|
41
|
+
`narrative` — and for a `chart` section exactly one chart type from
|
|
42
|
+
the house vocabulary: `line`, `band`, `rule`, `annotation`, `dot`,
|
|
43
|
+
`spark`, `bar`, `funnel`. Only a chart carries a chart type.
|
|
44
|
+
3. **Data and narrative instructions.** For each non-narrative section,
|
|
45
|
+
what should the data show (plain-language data instructions — the
|
|
46
|
+
capture lane compiles them; you never write SQL) and what should the
|
|
47
|
+
narrative say about it. A section may name an earlier SQL-backed
|
|
48
|
+
section's result as its `input`; chains must stay acyclic.
|
|
49
|
+
4. **One optional parameter.** A brief has at most one input parameter,
|
|
50
|
+
entity-typed: an entity type plus a display template (for example
|
|
51
|
+
`first_name + ' ' + last_name`). Members are picked later in the
|
|
52
|
+
builder's parameter sheet — never collect emails, and refer to people
|
|
53
|
+
by display name only.
|
|
54
|
+
|
|
55
|
+
Do not ask about cadence or recipients: schedules and delivery are
|
|
56
|
+
configured on the brief in the console, not stored in the template.
|
|
57
|
+
|
|
58
|
+
## Draft The Template
|
|
59
|
+
|
|
60
|
+
Make one `brain_brief_template_create` call with the interview's answers
|
|
61
|
+
as an `engine: "v2"` body — sections carry their instructions, but no
|
|
62
|
+
rules yet (rules only ever come from the capture lane below). Shape:
|
|
63
|
+
|
|
64
|
+
```json
|
|
65
|
+
{
|
|
66
|
+
"name": "Sales Rep Daily",
|
|
67
|
+
"body": {
|
|
68
|
+
"engine": "v2",
|
|
69
|
+
"instructions": "A daily performance brief for one sales rep. Confident, factual, no filler.",
|
|
70
|
+
"parameter": {
|
|
71
|
+
"entity_type": "Person",
|
|
72
|
+
"display_template": "first_name + ' ' + last_name"
|
|
73
|
+
},
|
|
74
|
+
"sections": [
|
|
75
|
+
{
|
|
76
|
+
"key": "open-pipeline",
|
|
77
|
+
"title": "Open Pipeline",
|
|
78
|
+
"type": "stat",
|
|
79
|
+
"data_rule": "Total open opportunity value and count for the selected rep.",
|
|
80
|
+
"narrative": "One sentence on how the headline number moved."
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
"key": "recent-orders",
|
|
84
|
+
"title": "Recent Orders",
|
|
85
|
+
"type": "table",
|
|
86
|
+
"data_rule": "The rep's orders from the last 7 days with customer, date, and value.",
|
|
87
|
+
"narrative": "Call out anything unusual; if nothing is unusual, say so."
|
|
88
|
+
},
|
|
89
|
+
{
|
|
90
|
+
"key": "stage-funnel",
|
|
91
|
+
"title": "Stage Funnel",
|
|
92
|
+
"type": "chart",
|
|
93
|
+
"chart_type": "funnel",
|
|
94
|
+
"input": "recent-orders",
|
|
95
|
+
"data_rule": "Opportunity counts by pipeline stage for the selected rep.",
|
|
96
|
+
"narrative": "Where the funnel narrows and why it might."
|
|
97
|
+
},
|
|
98
|
+
{
|
|
99
|
+
"key": "day-ahead",
|
|
100
|
+
"title": "The Day Ahead",
|
|
101
|
+
"type": "narrative",
|
|
102
|
+
"narrative": "Two or three priorities for today, grounded in the sections above."
|
|
103
|
+
}
|
|
104
|
+
]
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
The create result carries the `template_id` and a `builder_url`. Keep
|
|
110
|
+
both. If the create is refused (an unknown type, a chart type outside
|
|
111
|
+
the vocabulary, a cyclic input chain, a second parameter), relay the
|
|
112
|
+
refusal's reason, fix the draft with the operator, and retry.
|
|
113
|
+
|
|
114
|
+
## Capture The Rules
|
|
115
|
+
|
|
116
|
+
For each section that carries data instructions, in template order:
|
|
117
|
+
|
|
118
|
+
1. `brain_brief_rule_propose` with the `template_id` and the section's
|
|
119
|
+
`key`. The Brain compiles the section's data instructions into a
|
|
120
|
+
proposed, typed rule; the call returns a `task_id`.
|
|
121
|
+
2. Poll `brain_brief_rule_propose_result` with that `task_id` until the
|
|
122
|
+
proposal is ready. If the proposal fails, relay its reason and ask
|
|
123
|
+
whether to reword the section's data instructions or drop the
|
|
124
|
+
section.
|
|
125
|
+
3. `brain_brief_rule_preview` with the proposed rule. Show the operator
|
|
126
|
+
what came back — the real preview rows, honestly, including a zero-row
|
|
127
|
+
preview ("the reading was taken and nothing matched" is a real
|
|
128
|
+
answer, not a failure).
|
|
129
|
+
4. Only after the operator confirms a previewed rule,
|
|
130
|
+
`brain_brief_rule_accept` it. Never accept a rule that was not
|
|
131
|
+
previewed in this conversation, and never accept on the operator's
|
|
132
|
+
silence.
|
|
133
|
+
|
|
134
|
+
Never author a rule yourself. You do not write SQL, graph queries, or
|
|
135
|
+
retrieval specs — proposals come from the capture lane and nowhere else.
|
|
136
|
+
If the operator wants a different rule, reword the data instructions and
|
|
137
|
+
re-propose.
|
|
138
|
+
|
|
139
|
+
## Fence Refusals
|
|
140
|
+
|
|
141
|
+
Propose and preview run through the Brain's data fences. When a call
|
|
142
|
+
answers with a fence refusal — for example, no marts are classified for
|
|
143
|
+
the domain the section asks about, or the owner's reach does not cover a
|
|
144
|
+
table — relay the fence's reason to the operator verbatim, do not accept
|
|
145
|
+
anything for that section, and stop capturing it. Never substitute
|
|
146
|
+
fabricated rows, a guessed query, or a softened restatement of the
|
|
147
|
+
refusal. Classification and access are operator actions in the Brain
|
|
148
|
+
console; say so and move on to the remaining sections or finish.
|
|
149
|
+
|
|
150
|
+
## Handoff
|
|
151
|
+
|
|
152
|
+
Finish with a short summary — the template name, the sections drafted,
|
|
153
|
+
which rules were accepted and which sections still need attention — and
|
|
154
|
+
the builder link for review: the `builder_url` from the create result,
|
|
155
|
+
or the Brain console path `/analytics/reports/builder?template=<template_id>`.
|
|
156
|
+
The operator reviews, tweaks, picks parameter members, and saves there.
|
|
157
|
+
Refer to every person by display name, never by email.
|
|
158
|
+
|
|
159
|
+
## Stop Conditions
|
|
160
|
+
|
|
161
|
+
Stop and ask before proceeding when: the Brief Builder tools are missing
|
|
162
|
+
from the connector; the operator's answers leave a section without a
|
|
163
|
+
type or a chart without a chart type; a second parameter is requested;
|
|
164
|
+
every data section's capture was refused by a fence; or the operator
|
|
165
|
+
asks you to accept a rule whose preview they have not seen.
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: n8n-workflow-operator
|
|
3
|
+
description: Create, update, validate, test, and debug n8n workflows through the tenant's registered n8n MCP server. Use when a request names n8n, workflows, executions, Code node packages, workflow migration, automation drafts, or asks to create an automation from a thread.
|
|
4
|
+
license: Apache-2.0
|
|
5
|
+
compatibility: A registered n8n MCP server backed by a tenant n8n instance with instance-level MCP enabled.
|
|
6
|
+
metadata:
|
|
7
|
+
skill-format: agentskills
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# n8n Workflow Operator
|
|
11
|
+
|
|
12
|
+
Use n8n as a shared tenant automation runtime. Read live workflow and node
|
|
13
|
+
state, make draft-safe changes, validate the result, and leave production
|
|
14
|
+
activation to the shared native n8n operator unless the human explicitly says
|
|
15
|
+
otherwise.
|
|
16
|
+
|
|
17
|
+
## First Move
|
|
18
|
+
|
|
19
|
+
1. Use this skill before any n8n workflow create, update, validation, test, or
|
|
20
|
+
debug action.
|
|
21
|
+
2. Use the n8n MCP tools exposed by the tenant's registered n8n MCP server. It
|
|
22
|
+
authenticates with a tenant service credential, not per-user n8n activation.
|
|
23
|
+
3. If n8n tools are missing, report that an operator must register the n8n MCP
|
|
24
|
+
server in Connectors, enable instance-level MCP in n8n, and enable MCP
|
|
25
|
+
access on the workflow, project, or folder.
|
|
26
|
+
4. Trust live MCP tool descriptions and node schemas over memory. n8n changes
|
|
27
|
+
quickly; if a live tool or schema disagrees with this skill, follow the live
|
|
28
|
+
tool and report the drift in the handoff.
|
|
29
|
+
|
|
30
|
+
## Authoring Loop
|
|
31
|
+
|
|
32
|
+
For requests such as "create a workflow", "edit this workflow", or "make a
|
|
33
|
+
smoke test":
|
|
34
|
+
|
|
35
|
+
1. Classify the pattern: manual trigger, webhook, schedule, HTTP API
|
|
36
|
+
integration, database sync, AI agent, or batch processing.
|
|
37
|
+
2. Read [MCP tooling](references/mcp-tooling.md), then discover live node
|
|
38
|
+
schemas before configuring nodes.
|
|
39
|
+
3. Read [workflow authoring](references/workflow-authoring.md), then create or
|
|
40
|
+
update an inactive draft. Use UUID-shaped node ids, current `typeVersion`
|
|
41
|
+
values, and no placeholder credentials or secrets.
|
|
42
|
+
4. Validate iteratively. Treat validation errors as normal feedback: fix the
|
|
43
|
+
specific field, then validate again.
|
|
44
|
+
5. Fetch the workflow after every create or update and inspect `connections` so
|
|
45
|
+
silently dropped or wrong wires are caught before handoff.
|
|
46
|
+
6. Test only when safe. n8n test runs execute real HTTP calls, writes, sends,
|
|
47
|
+
and other side effects.
|
|
48
|
+
7. Finish with [validation and handoff](references/validation-and-handoff.md).
|
|
49
|
+
|
|
50
|
+
## ThinkWork Agent-Step Bridge
|
|
51
|
+
|
|
52
|
+
1. For n8n-to-ThinkWork agent work, use the v1 agent-step bridge with stock
|
|
53
|
+
HTTP Request and Wait nodes. Do not suggest a custom ThinkWork n8n node in
|
|
54
|
+
v1.
|
|
55
|
+
2. The HTTP Request node calls ThinkWork's
|
|
56
|
+
`/api/integrations/n8n/agent-steps` endpoint with the separate inbound
|
|
57
|
+
bridge credential. Do not reuse the native n8n MCP service credential.
|
|
58
|
+
3. The workflow must pass target Space, target agent, instructions, structured
|
|
59
|
+
input, workflow id/name, execution id, step id, correlation id, optional
|
|
60
|
+
request id, optional timeout, and the current Wait-node resume URL from
|
|
61
|
+
`$execution.resumeUrl`.
|
|
62
|
+
4. The Wait node should use On webhook call. Downstream nodes should branch on
|
|
63
|
+
the resumed payload's `status` and read `output`, `error`, `summary`,
|
|
64
|
+
and `links`; they should not scrape ThinkWork thread pages.
|
|
65
|
+
5. Explain idempotency as workflow id + execution id + correlation id + step
|
|
66
|
+
id. Retrying the same bridge step should recover or replay the existing
|
|
67
|
+
ThinkWork thread rather than creating a duplicate.
|
|
68
|
+
|
|
69
|
+
## Stop Conditions
|
|
70
|
+
|
|
71
|
+
Stop before writing when multiple workflows match, the workflow/project/folder
|
|
72
|
+
does not have MCP access enabled, credentials are unknown, a test would touch
|
|
73
|
+
production side effects, the user asks for production activation without using
|
|
74
|
+
the native n8n operator account, or the live MCP tool surface conflicts with
|
|
75
|
+
the requested action.
|
package/dist/workspace-defaults/files/catalog-skills/n8n-workflow-operator/references/mcp-tooling.md
ADDED
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# MCP Tooling
|
|
2
|
+
|
|
3
|
+
Use live n8n MCP tools as the source of truth for tool names, argument shapes,
|
|
4
|
+
node schemas, and current `typeVersion` values.
|
|
5
|
+
|
|
6
|
+
## Tool Selection
|
|
7
|
+
|
|
8
|
+
1. Search for nodes before configuring them.
|
|
9
|
+
2. Read the node schema before setting parameters. Standard detail is enough for
|
|
10
|
+
most nodes; use deeper docs only when the required field is unclear.
|
|
11
|
+
3. Validate nodes or workflows as soon as the tool surface supports it.
|
|
12
|
+
4. Prefer partial workflow updates for edits to existing workflows. Include a
|
|
13
|
+
short intent when the tool accepts one.
|
|
14
|
+
5. Fetch the workflow after create/update and inspect `connections`.
|
|
15
|
+
|
|
16
|
+
## Node Type Formats
|
|
17
|
+
|
|
18
|
+
Use the form expected by the tool being called:
|
|
19
|
+
|
|
20
|
+
1. Node discovery and node validation tools use short forms, for example
|
|
21
|
+
`nodes-base.httpRequest`.
|
|
22
|
+
2. Workflow JSON uses full forms, for example
|
|
23
|
+
`n8n-nodes-base.httpRequest`.
|
|
24
|
+
3. If a tool returns both forms, carry both forward instead of reconstructing
|
|
25
|
+
from memory.
|
|
26
|
+
|
|
27
|
+
## Credentials And Secrets
|
|
28
|
+
|
|
29
|
+
1. Never emit fake credential ids such as `REPLACE_ME`.
|
|
30
|
+
2. If the real credential id is unknown, omit the `credentials` block so the
|
|
31
|
+
native UI can show a usable selector.
|
|
32
|
+
3. Never put tokens, API keys, or passwords in Set nodes, Code nodes,
|
|
33
|
+
expressions, or plain text fields. Use the n8n credential system.
|
|
34
|
+
4. The ThinkWork agent-step bridge credential is separate from the n8n MCP
|
|
35
|
+
service credential.
|
|
36
|
+
|
|
37
|
+
## Shortened Tool Names
|
|
38
|
+
|
|
39
|
+
The ThinkWork runtime may expose long MCP tool names in shortened form. Choose
|
|
40
|
+
tools by descriptions and parameter schemas, not memorized exact names.
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# Validation And Handoff
|
|
2
|
+
|
|
3
|
+
Validation passing is necessary, not sufficient. A workflow can validate and
|
|
4
|
+
still have wrong wires, missing branches, or unsafe runtime behavior.
|
|
5
|
+
|
|
6
|
+
## Validation Loop
|
|
7
|
+
|
|
8
|
+
1. Validate configured nodes when available.
|
|
9
|
+
2. Create or update the inactive workflow.
|
|
10
|
+
3. Validate the complete workflow.
|
|
11
|
+
4. Fix one concrete error at a time, then validate again.
|
|
12
|
+
5. Treat warnings as context-sensitive. Production workflows should address
|
|
13
|
+
missing error handling, retry, rate-limit, and credential warnings unless
|
|
14
|
+
there is a clear reason to accept them.
|
|
15
|
+
|
|
16
|
+
## Verify After Write
|
|
17
|
+
|
|
18
|
+
After every create or update:
|
|
19
|
+
|
|
20
|
+
1. Fetch the workflow by id.
|
|
21
|
+
2. Confirm workflow id, name, active state, tags, project or folder, trigger
|
|
22
|
+
nodes, credential references, and MCP access state.
|
|
23
|
+
3. Inspect `connections` directly. Confirm each expected branch, error output,
|
|
24
|
+
and merge input is wired to the intended node.
|
|
25
|
+
4. If multiple workflows match, stop and ask for the exact workflow id or URL.
|
|
26
|
+
|
|
27
|
+
## Test Evidence
|
|
28
|
+
|
|
29
|
+
1. Ask before any test that can create records, call external APIs, send
|
|
30
|
+
messages, or mutate production systems.
|
|
31
|
+
2. Prefer disposable inputs and read-only endpoints.
|
|
32
|
+
3. Record execution ids, failure messages, validation errors, and evidence
|
|
33
|
+
links in the handoff.
|
|
34
|
+
|
|
35
|
+
## Handoff Checklist
|
|
36
|
+
|
|
37
|
+
Include workflow id, workflow name, draft/test status, package requirements,
|
|
38
|
+
credential assumptions, MCP access state, validation result, connection
|
|
39
|
+
verification result, test evidence, and the native n8n UI action required from
|
|
40
|
+
the shared operator.
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
# Workflow Authoring
|
|
2
|
+
|
|
3
|
+
Build the smallest inactive draft that proves the requested automation shape,
|
|
4
|
+
then validate and verify it before handoff.
|
|
5
|
+
|
|
6
|
+
## Pattern Choice
|
|
7
|
+
|
|
8
|
+
1. Manual trigger: use for user-triggered smoke tests and safe demos.
|
|
9
|
+
2. Webhook: use when an external system pushes an event.
|
|
10
|
+
3. Schedule: use for recurring fetch, report, and maintenance workflows.
|
|
11
|
+
4. HTTP API integration: use for read/write calls to external REST APIs.
|
|
12
|
+
5. Database sync: use for ETL and record reconciliation.
|
|
13
|
+
6. AI agent: use when the workflow needs model reasoning or n8n agent tools.
|
|
14
|
+
7. Batch processing: use when item count, pagination, or rate limits matter.
|
|
15
|
+
|
|
16
|
+
## Construction Rules
|
|
17
|
+
|
|
18
|
+
1. Prefer HTTP Request nodes over Code nodes for ordinary GET/POST calls.
|
|
19
|
+
2. Prefer expressions in the consuming field for simple data mapping.
|
|
20
|
+
3. Use `{{ ... }}` expressions in n8n fields. Use direct JavaScript only inside
|
|
21
|
+
Code nodes.
|
|
22
|
+
4. Avoid Set/Edit Fields nodes that feed a single consumer; inline the
|
|
23
|
+
expression at the consuming field.
|
|
24
|
+
5. For webhook workflows, user payload fields are under `$json.body`, not at
|
|
25
|
+
the root.
|
|
26
|
+
6. For branchy workflows, reference upstream nodes by name instead of relying on
|
|
27
|
+
ambiguous `$json` at branch convergence.
|
|
28
|
+
7. Search for existing workflows or templates before creating a larger reusable
|
|
29
|
+
workflow from scratch.
|
|
30
|
+
|
|
31
|
+
## Draft Safety
|
|
32
|
+
|
|
33
|
+
1. Keep created workflows inactive unless the human explicitly completes
|
|
34
|
+
production activation in the native n8n UI.
|
|
35
|
+
2. Prefer disabled copies or disposable draft workflows for edits.
|
|
36
|
+
3. Run only read-only or low-risk test executions without additional
|
|
37
|
+
confirmation.
|
|
38
|
+
4. Do not trigger a production webhook, schedule, message send, database write,
|
|
39
|
+
or destructive external side effect as a smoke test.
|
|
40
|
+
|
|
41
|
+
## Code Nodes
|
|
42
|
+
|
|
43
|
+
Use Code nodes only for multi-item aggregation, allowlisted package use, or
|
|
44
|
+
logic that cannot be expressed in fields. For Code nodes, use only packages
|
|
45
|
+
already available to the tenant's n8n deployment. Ask an operator to add a
|
|
46
|
+
package rather than assuming one is present.
|
|
@@ -15,7 +15,7 @@ Do not use emoji as icons, status markers, bullets, tab labels, headings, empty
|
|
|
15
15
|
Use the best sources available in this order:
|
|
16
16
|
|
|
17
17
|
1. Thread context and any attached or already retrieved CRM rows.
|
|
18
|
-
2. Available CRM, connector, MCP, context, workspace,
|
|
18
|
+
2. Available CRM, connector, MCP, context, workspace, or memory tools.
|
|
19
19
|
3. Email, calendar, and web context when the prompt asks for stale activity, next meetings, or external account risk.
|
|
20
20
|
4. A small demo or fixture-shaped dataset only when live sources are missing. Make limitations visible only when they materially affect the displayed result.
|
|
21
21
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: document-composer
|
|
3
|
-
description: 'Compose document deliverables —
|
|
3
|
+
description: 'Compose document deliverables — plans, memos, meeting notes, ideation summaries, external research write-ups, and any other genre registered for this workspace — as markdown that the platform compiles into a beautiful house-style document, saved as a durable artifact via emit_document. Use whenever the deliverable is document-shaped: the user asks for a plan, write-up, proposal, or ideation summary, or asks to "write this up" or "make a document", or when a substantial multi-section answer deserves a durable, shareable form instead of chat text. NOT for briefs or reports when a Company Brain is attached — those are minted by the Brain via brain_report_create, never composed here.'
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Document Composer
|
|
@@ -11,10 +11,29 @@ single body. The platform compiles the polished house-style HTML render
|
|
|
11
11
|
(layout, typography, dark mode, charts) at emission; you never write HTML.
|
|
12
12
|
The thread shows a compact card linking to the full-page reader.
|
|
13
13
|
|
|
14
|
+
## Briefs and reports belong to the Brain
|
|
15
|
+
|
|
16
|
+
**When a Company Brain connection is attached, you never compose a brief or
|
|
17
|
+
report yourself.** A brief composed locally has no flag lane, no cortex
|
|
18
|
+
review, and no learning loop — it is worthless to the business. If the
|
|
19
|
+
deliverable is a brief or report over company data (anything you gathered
|
|
20
|
+
through `brain_ask`, `brain_ask_submit` / `brain_ask_result`,
|
|
21
|
+
`brain_analytics_query`, `brain_search`, or any other `brain_*` tool), hand it
|
|
22
|
+
over to the Brain: call `brain_report_create` with the sections you composed.
|
|
23
|
+
It runs the rules, files a living report, and delivers the real brief card to
|
|
24
|
+
this thread. The runtime enforces this — `emit_document` refuses the `report`
|
|
25
|
+
and `brief` genres (and brief/report-titled documents) when a Brain is
|
|
26
|
+
attached, answering `{ ok: false, reason: "brief_is_brain_owned", ... }`.
|
|
27
|
+
When you see that refusal, do not retry under another genre or title: route
|
|
28
|
+
to `brain_report_create`.
|
|
29
|
+
|
|
30
|
+
Without a Brain attached, `report` and `brief` remain ordinary genres here.
|
|
31
|
+
|
|
14
32
|
## When to reach for a document
|
|
15
33
|
|
|
16
|
-
- The user asks for a plan,
|
|
17
|
-
|
|
34
|
+
- The user asks for a plan, analysis, proposal, or ideation summary — or to
|
|
35
|
+
"write this up" / "make a document". (A brief or report with a Brain
|
|
36
|
+
attached is the Brain's — see above.)
|
|
18
37
|
- Your answer is substantial (multiple sections, comparisons, decisions,
|
|
19
38
|
metrics) and will be revisited or shared. A document outlives the thread.
|
|
20
39
|
- NOT for short answers, quick lists, or conversational replies — those stay
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "thinkwork-cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "1.0.0",
|
|
4
4
|
"description": "Thinkwork CLI — deploy, manage, and interact with your Thinkwork stack",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"dist"
|
|
12
12
|
],
|
|
13
13
|
"scripts": {
|
|
14
|
-
"build": "tsup
|
|
14
|
+
"build": "tsup && node scripts/bundle-terraform.js",
|
|
15
15
|
"dev": "tsx src/cli.ts",
|
|
16
16
|
"codegen": "graphql-codegen --config codegen.ts",
|
|
17
17
|
"typecheck": "tsc --noEmit",
|
|
@@ -33,6 +33,7 @@
|
|
|
33
33
|
"@graphql-codegen/cli": "^5.0.6",
|
|
34
34
|
"@graphql-codegen/client-preset": "^4.8.2",
|
|
35
35
|
"@thinkwork/admin-ops": "workspace:*",
|
|
36
|
+
"@thinkwork/api": "workspace:*",
|
|
36
37
|
"@thinkwork/database-pg": "workspace:*",
|
|
37
38
|
"@types/node": "^25.6.0",
|
|
38
39
|
"tsup": "^8.0.0",
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
-- THINK-307 KTD4: the retry dispatcher's successor-turn guard, THINK-308's
|
|
2
|
-
-- finalize reconciliation, and THINK-309's recovery resolver all look up
|
|
3
|
-
-- thread_turns by origin_turn_id; no index covers that column today.
|
|
4
|
-
-- Additive — safe to apply ahead of code deploy.
|
|
5
|
-
--
|
|
6
|
-
-- Hand-rolled (drizzle meta journal is not in use for this change);
|
|
7
|
-
-- apply with: psql "$DATABASE_URL" -f drizzle/0261_thread_turns_origin_turn_index.sql
|
|
8
|
-
-- creates: public.idx_thread_turns_origin_turn
|
|
9
|
-
|
|
10
|
-
CREATE INDEX IF NOT EXISTS idx_thread_turns_origin_turn
|
|
11
|
-
ON public.thread_turns (origin_turn_id);
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
# Company Data Plugin
|
|
2
|
-
|
|
3
|
-
The Company Data plugin is the package-owned source boundary for the
|
|
4
|
-
first-party operational facts substrate. This slice publishes the stable
|
|
5
|
-
catalog identity and normal ThinkWork install path before any live Company Data
|
|
6
|
-
runtime exists.
|
|
7
|
-
|
|
8
|
-
The shell intentionally does not deploy extraction runners, projection database
|
|
9
|
-
schema, mapping workflows, schedules, pipelines, MCP servers, skills,
|
|
10
|
-
credentials, datalake, warehouse, query engine, monitoring, analytics UI, BI,
|
|
11
|
-
Context Engine providers, live operator UI, source-system writes, or
|
|
12
|
-
Terraform-managed resources. Future Company Data work should extend this
|
|
13
|
-
`company-data` package and version line with explicit requirements,
|
|
14
|
-
handler-backed components, and deployed verification before introducing runtime
|
|
15
|
-
capability.
|
|
16
|
-
|
|
17
|
-
## Owned Source
|
|
18
|
-
|
|
19
|
-
- `src/manifest.ts` declares the catalog manifest with empty OAuth scopes,
|
|
20
|
-
no capabilities, and one declared-only `ui-surface` component.
|
|
21
|
-
- `test/manifest.test.ts` validates the shell boundary, manifest shape,
|
|
22
|
-
customer-facing operational facts copy, and deferred-resource language.
|
|
23
|
-
|
|
24
|
-
## Shell Scope
|
|
25
|
-
|
|
26
|
-
V1 is deliberately narrow:
|
|
27
|
-
|
|
28
|
-
- Company Data appears in the first-party plugin catalog as
|
|
29
|
-
`company-data@0.1.0`.
|
|
30
|
-
- Tenant administrators can install the shell through the normal plugin
|
|
31
|
-
install flow.
|
|
32
|
-
- The plugin engine records only the install and one no-op UI-surface component
|
|
33
|
-
with an empty handler reference.
|
|
34
|
-
- Live extraction runtime, projection schema, mapping workflows, schedules,
|
|
35
|
-
pipelines, MCP servers, skills, credentials, Context Engine providers,
|
|
36
|
-
analytics UI, BI, lakehouse query UI, source-system writes, and
|
|
37
|
-
infrastructure are deferred follow-up work.
|
|
38
|
-
|
|
39
|
-
## Verification Notes
|
|
40
|
-
|
|
41
|
-
Package-local verification:
|
|
42
|
-
|
|
43
|
-
```bash
|
|
44
|
-
pnpm --filter @thinkwork/plugin-company-data test
|
|
45
|
-
pnpm --filter @thinkwork/plugin-company-data typecheck
|
|
46
|
-
pnpm --filter @thinkwork/plugin-catalog test
|
|
47
|
-
pnpm --filter @thinkwork/plugin-catalog typecheck
|
|
48
|
-
node scripts/verify-plugin-source-boundary.mjs
|
|
49
|
-
```
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@thinkwork/plugin-company-data",
|
|
3
|
-
"version": "0.0.0",
|
|
4
|
-
"private": true,
|
|
5
|
-
"type": "module",
|
|
6
|
-
"main": "./src/index.ts",
|
|
7
|
-
"exports": {
|
|
8
|
-
".": "./src/index.ts",
|
|
9
|
-
"./manifest": "./src/manifest.ts"
|
|
10
|
-
},
|
|
11
|
-
"scripts": {
|
|
12
|
-
"build": "tsc --build",
|
|
13
|
-
"typecheck": "tsc --noEmit",
|
|
14
|
-
"test": "vitest run"
|
|
15
|
-
},
|
|
16
|
-
"devDependencies": {
|
|
17
|
-
"@thinkwork/plugin-catalog": "workspace:*",
|
|
18
|
-
"typescript": "^5.5.0",
|
|
19
|
-
"vitest": "^2.0.0"
|
|
20
|
-
}
|
|
21
|
-
}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { companyDataManifest } from "./manifest";
|
|
2
|
-
|
|
3
|
-
export const companyDataPluginPackage = {
|
|
4
|
-
packageKey: "company-data",
|
|
5
|
-
sourceRoot: "plugins/company-data",
|
|
6
|
-
manifest: companyDataManifest,
|
|
7
|
-
ownedSources: [
|
|
8
|
-
{
|
|
9
|
-
kind: "manifest",
|
|
10
|
-
path: "plugins/company-data/src/manifest.ts",
|
|
11
|
-
description:
|
|
12
|
-
"Company Data catalog manifest for the shell-only plugin identity.",
|
|
13
|
-
},
|
|
14
|
-
{
|
|
15
|
-
kind: "docs",
|
|
16
|
-
path: "plugins/company-data/README.md",
|
|
17
|
-
description:
|
|
18
|
-
"Company Data package ownership and deferred resource notes.",
|
|
19
|
-
},
|
|
20
|
-
{
|
|
21
|
-
kind: "tests",
|
|
22
|
-
path: "plugins/company-data/test",
|
|
23
|
-
description:
|
|
24
|
-
"Company Data package-local manifest and shell-boundary tests.",
|
|
25
|
-
},
|
|
26
|
-
],
|
|
27
|
-
compatibilityLinks: [],
|
|
28
|
-
} as const;
|
|
29
|
-
|
|
30
|
-
export { companyDataManifest };
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import type { PluginManifest } from "@thinkwork/plugin-catalog/contracts";
|
|
2
|
-
|
|
3
|
-
export const COMPANY_DATA_SETTINGS_SURFACE =
|
|
4
|
-
"settings.plugins.detail.tab" as const;
|
|
5
|
-
|
|
6
|
-
export const companyDataManifest = {
|
|
7
|
-
pluginKey: "company-data",
|
|
8
|
-
displayName: "ThinkWork Data Warehouse",
|
|
9
|
-
description:
|
|
10
|
-
"Establishes a governed operational facts substrate for agent and UI reads. Extraction runners, projection databases, Context Engine providers, MCP tools, analytics, BI, and source-system writes belong to later ThinkWork Data Warehouse releases.",
|
|
11
|
-
versions: [
|
|
12
|
-
{
|
|
13
|
-
version: "0.1.0",
|
|
14
|
-
requiredOauthScopes: [],
|
|
15
|
-
capabilities: [],
|
|
16
|
-
components: [
|
|
17
|
-
{
|
|
18
|
-
type: "ui-surface",
|
|
19
|
-
key: "settings",
|
|
20
|
-
displayName: "ThinkWork Data Warehouse settings",
|
|
21
|
-
intendedMount: COMPANY_DATA_SETTINGS_SURFACE,
|
|
22
|
-
},
|
|
23
|
-
],
|
|
24
|
-
},
|
|
25
|
-
],
|
|
26
|
-
} satisfies PluginManifest;
|