@arcbridge/core 0.1.4 → 0.1.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.
package/dist/index.d.ts CHANGED
@@ -448,13 +448,13 @@ declare const PhaseSchema: z.ZodObject<{
448
448
  declare const TaskSchema: z.ZodObject<{
449
449
  id: z.ZodString;
450
450
  title: z.ZodString;
451
- status: z.ZodDefault<z.ZodEnum<["todo", "in-progress", "done", "blocked"]>>;
451
+ status: z.ZodDefault<z.ZodEnum<["todo", "in-progress", "done", "blocked", "cancelled"]>>;
452
452
  building_block: z.ZodOptional<z.ZodString>;
453
453
  quality_scenarios: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
454
454
  acceptance_criteria: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
455
455
  completed_at: z.ZodOptional<z.ZodString>;
456
456
  }, "strip", z.ZodTypeAny, {
457
- status: "in-progress" | "blocked" | "todo" | "done";
457
+ status: "in-progress" | "blocked" | "todo" | "done" | "cancelled";
458
458
  id: string;
459
459
  quality_scenarios: string[];
460
460
  title: string;
@@ -464,7 +464,7 @@ declare const TaskSchema: z.ZodObject<{
464
464
  }, {
465
465
  id: string;
466
466
  title: string;
467
- status?: "in-progress" | "blocked" | "todo" | "done" | undefined;
467
+ status?: "in-progress" | "blocked" | "todo" | "done" | "cancelled" | undefined;
468
468
  quality_scenarios?: string[] | undefined;
469
469
  completed_at?: string | undefined;
470
470
  building_block?: string | undefined;
@@ -531,13 +531,13 @@ declare const TaskFileSchema: z.ZodObject<{
531
531
  tasks: z.ZodArray<z.ZodObject<{
532
532
  id: z.ZodString;
533
533
  title: z.ZodString;
534
- status: z.ZodDefault<z.ZodEnum<["todo", "in-progress", "done", "blocked"]>>;
534
+ status: z.ZodDefault<z.ZodEnum<["todo", "in-progress", "done", "blocked", "cancelled"]>>;
535
535
  building_block: z.ZodOptional<z.ZodString>;
536
536
  quality_scenarios: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
537
537
  acceptance_criteria: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
538
538
  completed_at: z.ZodOptional<z.ZodString>;
539
539
  }, "strip", z.ZodTypeAny, {
540
- status: "in-progress" | "blocked" | "todo" | "done";
540
+ status: "in-progress" | "blocked" | "todo" | "done" | "cancelled";
541
541
  id: string;
542
542
  quality_scenarios: string[];
543
543
  title: string;
@@ -547,7 +547,7 @@ declare const TaskFileSchema: z.ZodObject<{
547
547
  }, {
548
548
  id: string;
549
549
  title: string;
550
- status?: "in-progress" | "blocked" | "todo" | "done" | undefined;
550
+ status?: "in-progress" | "blocked" | "todo" | "done" | "cancelled" | undefined;
551
551
  quality_scenarios?: string[] | undefined;
552
552
  completed_at?: string | undefined;
553
553
  building_block?: string | undefined;
@@ -557,7 +557,7 @@ declare const TaskFileSchema: z.ZodObject<{
557
557
  schema_version: 1;
558
558
  phase_id: string;
559
559
  tasks: {
560
- status: "in-progress" | "blocked" | "todo" | "done";
560
+ status: "in-progress" | "blocked" | "todo" | "done" | "cancelled";
561
561
  id: string;
562
562
  quality_scenarios: string[];
563
563
  title: string;
@@ -570,7 +570,7 @@ declare const TaskFileSchema: z.ZodObject<{
570
570
  tasks: {
571
571
  id: string;
572
572
  title: string;
573
- status?: "in-progress" | "blocked" | "todo" | "done" | undefined;
573
+ status?: "in-progress" | "blocked" | "todo" | "done" | "cancelled" | undefined;
574
574
  quality_scenarios?: string[] | undefined;
575
575
  completed_at?: string | undefined;
576
576
  building_block?: string | undefined;
@@ -734,7 +734,7 @@ declare function openMemoryDatabase(): Database;
734
734
  */
735
735
  declare function transaction<T>(db: Database, fn: () => T): T;
736
736
 
737
- declare const CURRENT_SCHEMA_VERSION = 2;
737
+ declare const CURRENT_SCHEMA_VERSION = 3;
738
738
  declare function initializeSchema(db: Database): void;
739
739
 
740
740
  declare function migrate(db: Database): void;
@@ -908,10 +908,30 @@ declare function addTaskToYaml(projectRoot: string, phaseId: string, task: {
908
908
  * Update a phase's status in phases.yaml.
909
909
  */
910
910
  declare function syncPhaseToYaml(projectRoot: string, phaseId: string, status: string, startedAt?: string | null, completedAt?: string | null): void;
911
+ /**
912
+ * Add a new phase to the phases.yaml file.
913
+ */
914
+ declare function addPhaseToYaml(projectRoot: string, phase: {
915
+ id: string;
916
+ name: string;
917
+ phase_number: number;
918
+ description: string;
919
+ gate_requirements?: string[];
920
+ }): {
921
+ success: boolean;
922
+ warning?: string;
923
+ };
911
924
  /**
912
925
  * Update a quality scenario's status in 10-quality-scenarios.yaml.
913
926
  */
914
- declare function syncScenarioToYaml(projectRoot: string, scenarioId: string, status: string): void;
927
+ declare function syncScenarioToYaml(projectRoot: string, scenarioId: string, status: string, linkedTests?: string[], verification?: string): void;
928
+ /**
929
+ * Delete a task from the YAML task file.
930
+ */
931
+ declare function deleteTaskFromYaml(projectRoot: string, phaseId: string, taskId: string): {
932
+ success: boolean;
933
+ warning?: string;
934
+ };
915
935
 
916
936
  /**
917
937
  * Generate sync loop trigger files based on configured platforms.
@@ -1050,6 +1070,12 @@ declare function getHeadSha(projectRoot: string): string | null;
1050
1070
  * Store the current sync point in arcbridge_meta.
1051
1071
  */
1052
1072
  declare function setSyncCommit(db: Database, key: "last_sync_commit" | "phase_sync_commit", sha: string): void;
1073
+ /**
1074
+ * Filter changed files to only those within the project directory.
1075
+ * In monorepo setups, getChangedFiles returns all repo changes —
1076
+ * this scopes them to the project's subdirectory.
1077
+ */
1078
+ declare function scopeToProject(changedFiles: ChangedFile[], projectRoot: string): ChangedFile[];
1053
1079
 
1054
1080
  type TestOutcome = "passed" | "failed" | "missing" | "error";
1055
1081
  interface ScenarioTestResult {
@@ -1110,4 +1136,4 @@ declare function loadConfig(projectRoot: string): {
1110
1136
  error: string | null;
1111
1137
  };
1112
1138
 
1113
- export { type ActivityRow, type AdrFrontmatter, AdrFrontmatterSchema, type AgentRole, AgentRoleSchema, type AggregatedRow, type ArcBridgeConfig, ArcBridgeConfigSchema, type BuildingBlock, BuildingBlockSchema, type BuildingBlocksFrontmatter, BuildingBlocksFrontmatterSchema, CURRENT_SCHEMA_VERSION, type ChangedFile, type Database, type DotnetProjectInfo, type DriftEntry, type DriftKind, type DriftOptions, type DriftSeverity, type ExportFormat, type ExtractedSymbol, type GenerateDatabaseResult, type GitRef, type IndexResult, type IndexerOptions, type InitProjectInput, type InsertActivityParams, type LatestQualitySnapshot, type LoadRolesResult, type MetricsResult, type Phase, PhaseSchema, type PhasesFile, PhasesFileSchema, type ProjectLanguage, QualityCategorySchema, QualityPrioritySchema, type QualityScenario, QualityScenarioSchema, QualityScenarioStatusSchema, type QualityScenariosFile, QualityScenariosFileSchema, type QueryMetricsParams, type ScenarioTestResult, type Service, type SessionTotals, type SymbolKind, type Task, type TaskFile, TaskFileSchema, type TaskInferenceResult, TaskSchema, type TestOutcome, type VerifyResult, addTaskToYaml, applyInferences, detectDrift, detectProjectLanguage, discoverDotnetServices, exportMetrics, generateAgentRoles, generateArc42, generateConfig, generateDatabase, generatePlan, generateSyncFiles, getChangedFiles, getHeadSha, getSessionTotals, getUncommittedChanges, indexPackageDependencies, indexProject, inferTaskStatuses, initializeSchema, insertActivity, loadConfig, loadRole, loadRoles, migrate, openDatabase, openMemoryDatabase, queryMetrics, refreshFromDocs, resolveRef, setSyncCommit, suppressSqliteWarning, syncPhaseToYaml, syncScenarioToYaml, syncTaskToYaml, transaction, verifyScenarios, writeDriftLog };
1139
+ export { type ActivityRow, type AdrFrontmatter, AdrFrontmatterSchema, type AgentRole, AgentRoleSchema, type AggregatedRow, type ArcBridgeConfig, ArcBridgeConfigSchema, type BuildingBlock, BuildingBlockSchema, type BuildingBlocksFrontmatter, BuildingBlocksFrontmatterSchema, CURRENT_SCHEMA_VERSION, type ChangedFile, type Database, type DotnetProjectInfo, type DriftEntry, type DriftKind, type DriftOptions, type DriftSeverity, type ExportFormat, type ExtractedSymbol, type GenerateDatabaseResult, type GitRef, type IndexResult, type IndexerOptions, type InitProjectInput, type InsertActivityParams, type LatestQualitySnapshot, type LoadRolesResult, type MetricsResult, type Phase, PhaseSchema, type PhasesFile, PhasesFileSchema, type ProjectLanguage, QualityCategorySchema, QualityPrioritySchema, type QualityScenario, QualityScenarioSchema, QualityScenarioStatusSchema, type QualityScenariosFile, QualityScenariosFileSchema, type QueryMetricsParams, type ScenarioTestResult, type Service, type SessionTotals, type SymbolKind, type Task, type TaskFile, TaskFileSchema, type TaskInferenceResult, TaskSchema, type TestOutcome, type VerifyResult, addPhaseToYaml, addTaskToYaml, applyInferences, deleteTaskFromYaml, detectDrift, detectProjectLanguage, discoverDotnetServices, exportMetrics, generateAgentRoles, generateArc42, generateConfig, generateDatabase, generatePlan, generateSyncFiles, getChangedFiles, getHeadSha, getSessionTotals, getUncommittedChanges, indexPackageDependencies, indexProject, inferTaskStatuses, initializeSchema, insertActivity, loadConfig, loadRole, loadRoles, migrate, openDatabase, openMemoryDatabase, queryMetrics, refreshFromDocs, resolveRef, scopeToProject, setSyncCommit, suppressSqliteWarning, syncPhaseToYaml, syncScenarioToYaml, syncTaskToYaml, transaction, verifyScenarios, writeDriftLog };