chati-dev 4.5.5 → 4.5.6

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.
Files changed (43) hide show
  1. package/bin/chati.js +35 -1
  2. package/framework/agents/plan/tasks.md +1 -1
  3. package/framework/config.yaml +8 -17
  4. package/framework/constitution.md +30 -20
  5. package/framework/context/governance.md +3 -1
  6. package/framework/context/root.md +1 -1
  7. package/framework/data/entity-registry.yaml +2 -2
  8. package/framework/domains/agents/orchestrator.yaml +1 -1
  9. package/framework/domains/constitution.yaml +1 -1
  10. package/framework/domains/global.yaml +2 -2
  11. package/framework/hooks/model-governance.js +9 -0
  12. package/framework/manifest.json +38 -38
  13. package/framework/manifest.sig +1 -1
  14. package/framework/orchestrator/chati.md +27 -3
  15. package/framework/schemas/session.schema.json +1 -1
  16. package/framework/tasks/brownfield-wu-architecture-map.md +1 -1
  17. package/framework/tasks/brownfield-wu-deep-discovery.md +1 -1
  18. package/framework/tasks/brownfield-wu-dependency-scan.md +1 -1
  19. package/framework/tasks/brownfield-wu-migration-plan.md +1 -1
  20. package/framework/tasks/brownfield-wu-report.md +1 -1
  21. package/framework/tasks/brownfield-wu-risk-assess.md +1 -1
  22. package/framework/tasks/greenfield-wu-report.md +1 -1
  23. package/node_modules/@chati/provider-registry/src/index.js +3 -2
  24. package/node_modules/@chati/tracking-clickup/src/index.js +22 -0
  25. package/package.json +1 -1
  26. package/src/config/gemini-hooks-generator.js +10 -4
  27. package/src/dashboard/layout.js +6 -4
  28. package/src/installer/core.js +16 -0
  29. package/src/installer/templates.js +21 -1
  30. package/src/installer-v2/clickup-preflight.js +32 -0
  31. package/src/installer-v2/model-catalog-envelope.json +15 -13
  32. package/src/installer-v2/model-catalog.json +5 -5
  33. package/src/installer-v2/model-catalog.sig +1 -1
  34. package/src/installer-v2/wizard-installation.js +1 -1
  35. package/src/intelligence/registry-manager.js +9 -3
  36. package/src/orchestrator/cli.js +36 -21
  37. package/src/orchestrator/clickup-projection.js +25 -8
  38. package/src/orchestrator/clickup-runtime.js +89 -1
  39. package/src/orchestrator/planning-runtime.js +1 -2
  40. package/src/orchestrator/rail-runtime.js +1 -2
  41. package/src/orchestrator/runtime-installation-v2.js +10 -1
  42. package/src/wizard/index.js +8 -0
  43. package/src/wizard/questions.js +7 -3
@@ -85,8 +85,7 @@ function loadProjectRail({ projectDir, handoff_id, clock }) {
85
85
 
86
86
  function internalTrackingInstallation(projectDir, clock) {
87
87
  const artifact = loadRuntimeInstallationV2(projectDir, { ...(clock === undefined ? {} : { clock }) });
88
- return artifact?.installation?.profile === 'focus-ai-internal'
89
- && artifact.installation.external_integrations?.clickup === 'required';
88
+ return artifact?.installation?.external_integrations?.clickup === 'required';
90
89
  }
91
90
 
92
91
  function assertCompletionMetricsEvidence(metrics, reviews, acceptanceEvidenceRefs, records, attemptId) {
@@ -48,9 +48,18 @@ export function resolveRuntimeInvocationV2({ artifact, agent, binding, model_id,
48
48
  if (!selectedCandidate) throw Object.assign(new Error(`No eligible installed model for ${agent}/${action}`), { code: 'NO_ELIGIBLE_MODEL' });
49
49
  const selected = selectedCandidate.binding;
50
50
  const model = selectedCandidate.model.model_id;
51
+ const defaultReasoning = selectedCandidate.model.tier === 'worker'
52
+ ? 'low'
53
+ : selectedCandidate.model.tier === 'workhorse'
54
+ ? 'medium'
55
+ : 'high';
51
56
  const invocation = {
52
57
  provider_id: selected.provider_id, harness_id: selected.harness_id, action,
53
- model_pin: { model_id: model, catalog_snapshot_ref: artifact.capability_snapshot.snapshot_id, reasoning_configuration },
58
+ model_pin: {
59
+ model_id: model,
60
+ catalog_snapshot_ref: artifact.capability_snapshot.snapshot_id,
61
+ reasoning_configuration: reasoning_configuration ?? defaultReasoning,
62
+ },
54
63
  };
55
64
  assertEligibleInvocation({ installation: artifact.installation, snapshot: artifact.capability_snapshot, invocation, clock });
56
65
  return Object.freeze(invocation);
@@ -9,6 +9,7 @@ import { installFramework } from '../installer/core.js';
9
9
  import { INSTALLATION_ARTIFACT_PATH, dryRunV2, installV2, reconfigureV2 } from '../installer-v2/index.js';
10
10
  import { buildWizardV2InstallationInput } from '../installer-v2/wizard-installation.js';
11
11
  import { resolveCapabilityCatalog, verifySignedCapabilityCatalog } from '../installer-v2/catalog-client.js';
12
+ import { checkClickUpMcp } from '../installer-v2/clickup-preflight.js';
12
13
  import { validateInstallation } from '../installer/validator.js';
13
14
  import { initCollector, track as telemetryTrack, flush as telemetryFlush } from '../telemetry/collector.js';
14
15
  import { sendEvents } from '../telemetry/sender.js';
@@ -72,6 +73,7 @@ export async function runWizard(targetDir, options = {}) {
72
73
  let catalogResolution;
73
74
  let modelSelections;
74
75
  let installationMode;
76
+ let clickupPreflight = null;
75
77
  // Editor rule files are a legacy programmatic integration. The interactive
76
78
  // installer configures provider CLIs only, which are the actual runtimes.
77
79
  const selectedEditors = options.editors || [];
@@ -152,6 +154,11 @@ export async function runWizard(targetDir, options = {}) {
152
154
  p.log.error(error.message);
153
155
  continue;
154
156
  }
157
+ clickupPreflight = options.clickupPreflight || checkClickUpMcp(selectedProviders);
158
+ if (!clickupPreflight.passed) {
159
+ p.log.error('Internal mode requires an authorized ClickUp MCP connection in at least one selected CLI. Configure ClickUp in Claude, Codex or Grok, then retry.');
160
+ continue;
161
+ }
155
162
  }
156
163
  stage = 'confirm';
157
164
  continue;
@@ -173,6 +180,7 @@ export async function runWizard(targetDir, options = {}) {
173
180
  selectedIDEs,
174
181
  selectedMCPs,
175
182
  installationMode,
183
+ clickupPreflight,
176
184
  modelSelections,
177
185
  targetDir,
178
186
  version: VERSION,
@@ -120,8 +120,8 @@ export async function stepProviderSelection({ allowBack = false } = {}) {
120
120
  }
121
121
 
122
122
  /**
123
- * Selects the operational policy profile. Focus AI internal projects require
124
- * ClickUp tracking; standard projects do not gain that external dependency.
123
+ * Selects the operational policy profile. Authorized internal projects require
124
+ * ClickUp tracking; open projects do not gain that external dependency.
125
125
  */
126
126
  export async function stepInstallationMode({ allowBack = false } = {}) {
127
127
  const mode = await p.select({
@@ -257,7 +257,7 @@ export async function stepModelSelection(providers, capabilityCatalog) {
257
257
  * Step 4: Confirmation
258
258
  */
259
259
  export async function stepConfirmation(config, { allowBack = false } = {}) {
260
- const { projectName, projectType, language, selectedMCPs, selectedIDEs, allProviders, installationMode } = config;
260
+ const { projectName, projectType, language, selectedMCPs, selectedIDEs, allProviders, installationMode, clickupPreflight } = config;
261
261
 
262
262
  const langName = SUPPORTED_LANGUAGES.find(l => l.value === language)?.label || language;
263
263
 
@@ -288,6 +288,10 @@ export async function stepConfirmation(config, { allowBack = false } = {}) {
288
288
  summaryData[t('installer.ides_label')] = editorNames;
289
289
  }
290
290
 
291
+ if (installationMode === 'internal') {
292
+ summaryData.ClickUp = `Connected via ${(clickupPreflight?.connected_providers || []).join(', ')}`;
293
+ }
294
+
291
295
  summaryData[t('installer.mcps_label')] = mcpNames;
292
296
 
293
297
  console.log();