Skip to content

Local code intelligence for developers and AI agents. Connect code, docs and infrastructure in a persistent graph, with CBM Lens, MCP tools, agent integrations and change-aware test selection.

chore(pipeline): integrate upstream language documentation and diagrams

Pcristin65474cead19e
diff --cc src/pipeline/pipeline_internal.h
index 9c4b67c95,da925d2ab..5e58410c7
--- a/src/pipeline/pipeline_internal.h
+++ b/src/pipeline/pipeline_internal.h
@@@ -1279,13 -1282,14 +1282,21 @@@ int cbm_pipeline_build_fresh_semantic_m
* properties are read with their escapes, admission is best-first and
* every edge carries "p"; doc_link_candidates holds doc section -> code
* candidates. An index built before has the old pairs and no
- * candidates, so it rebuilds once on upgrade.
- * 8: combine these changes with unresolved-call evidence capture and its
- * candidate index. This branch's earlier versions 5 and 6 did not have
- * the document-link and TF-IDF layers; upstream version 7 did not have
- * unresolved-call capture. Both require a full rebuild on upgrade.
+ * candidates, so it rebuilds once on upgrade. Released together with
+ * 7 (no release in between, so no number of its own): doc comments of
+ * Go, Java, Kotlin, Rust, Perl, TS/JS, PHP and C hold MENTIONS edges;
+ * diagrams are Diagram/DiagramElement nodes with DIAGRAM_ARROW edges;
+ * OpenAPI operations are Routes; a Markdown section's text keeps a
+ * diagram fence's labels instead of its syntax, and its candidates
- * carry the p of its diagrams' kind family. */
-enum { CBM_SEMANTIC_INDEX_VERSION = 7 };
++ * carry the p of its diagrams' kind family.
++ * 8: combine document links and TF-IDF with unresolved-call evidence
++ * capture and its candidate index. This branch's earlier versions 5
++ * and 6 lacked the document layers; upstream 7 lacked call capture.
++ * 9: combine unresolved-call capture with the language documentation and
++ * diagram layers above. This branch's version 8 predates those layers,
++ * so unchanged files must rebuild once on upgrade.
+ * The unresolved-call coverage threshold remains independent. */
- enum { CBM_SEMANTIC_INDEX_VERSION = 8 };
++enum { CBM_SEMANTIC_INDEX_VERSION = 9 };
typedef struct {
cbm_gbuf_t *gbuf;
diff --cc tests/test_pipeline.c
index 76d420746,7684868e4..0de1cdfd7
--- a/tests/test_pipeline.c
+++ b/tests/test_pipeline.c
@@@ -5459,7 -5131,7 +5459,7 @@@ TEST(pipeline_capture_failure_preserves
* complete replacement even when every semantic-input byte is unchanged; the
* replacement must write current metadata so the next identical run is a
* true no-op. Cheaper requests retain fuller published coverage separately. */
--TEST(pipeline_exact_inputs_migrate_coverage_metadata_and_index_mode) {
++static int pipeline_exact_inputs_migrate_metadata_and_mode(int legacy_version) {
char tmp[256];
snprintf(tmp, sizeof(tmp), "/tmp/cbm_manifest_metadata_XXXXXX");
ASSERT_NOT_NULL(cbm_mkdtemp(tmp));
@@@ -5491,7 -5163,7 +5491,7 @@@
cbm_coverage_meta_t current_meta = {0};
ASSERT_EQ(cbm_store_coverage_meta_get(metadata_store, project, &current_meta), CBM_STORE_OK);
cbm_coverage_meta_t legacy_meta = current_meta;
-- legacy_meta.coverage_version = 1;
++ legacy_meta.coverage_version = legacy_version;
ASSERT_EQ(cbm_store_coverage_replace_ex(metadata_store, project, coverage_rows, coverage_count,
&legacy_meta),
CBM_STORE_OK);
@@@ -5558,6 -5230,6 +5558,16 @@@
PASS();
}
++TEST(pipeline_exact_inputs_migrate_coverage_metadata_and_index_mode) {
++ return pipeline_exact_inputs_migrate_metadata_and_mode(1);
++}
++
++/* Published branch version 8 predates language doc links and diagrams.
++ * Unchanged inputs still need a rebuild, followed by an exact no-op. */
++TEST(pipeline_semantic_version_8_index_is_rebuilt_once) {
++ return pipeline_exact_inputs_migrate_metadata_and_mode(8);
++}
++
typedef struct {
bool published;
int rename_calls;
@@@ -20692,7 -20487,6 +20837,8 @@@ SUITE(pipeline_semantic_manifest_repro
RUN_TEST(pipeline_source_addition_before_publication_preserves_previous_generation);
RUN_TEST(pipeline_tsconfig_mutation_before_publication_preserves_previous_generation);
RUN_TEST(pipeline_exact_inputs_migrate_coverage_metadata_and_index_mode);
++ RUN_TEST(pipeline_semantic_version_8_index_is_rebuilt_once);
+ RUN_TEST(pipeline_capture_failure_preserves_general_coverage_and_rebuilds);
RUN_TEST(pipeline_existing_artifact_refreshes_after_default_forced_full_reindex);
RUN_TEST(pipeline_full_cancel_after_predump_preserves_previous_generation);
RUN_TEST(pipeline_full_cancel_after_destination_prepare_preserves_previous_generation);