release: bump to 2.1.2 (EK production chain + View V0–V3 bar)

Ship evidence/closure invalidation, verify/adjudicate, reuse_execute and
agent bind/publish gates, document.extract, KnowledgePresentation + SSE
page_token, and upload max_bytes with the 45-test offline gate.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
cflmyandCursor committed 2026-10-24 22:52:03 +08:00
1 parent 0b80ff8e50
commit dc853fb580
38 files changed
+3045 -298

No files matched your search

+47
View File
@@ -37,6 +37,7 @@ pub fn compile(opts: KnowledgeOptions) -> Result<KnowledgeGraph> {
};
let graph = extract_graph(&extract_opts)?;
write_projections(&opts.out_dir, &graph)?;
write_publish_manifest(&opts.out_dir, &semantic, &graph)?;
eprintln!(
"marqdo knowledge: {} module(s), {} symbol(s), {} capability(ies), {} knowledge → {} (semantic graph/; retrieval ekc/)",
graph.modules.len(),
@@ -48,6 +49,52 @@ pub fn compile(opts: KnowledgeOptions) -> Result<KnowledgeGraph> {
Ok(graph)
}
/// M06: associate semantic generation, retrieval generation, and source digests.
fn write_publish_manifest(
out_dir: &Path,
semantic: &crate::sema::Compilation,
graph: &KnowledgeGraph,
) -> Result<()> {
let current = fs::read_to_string(out_dir.join("CURRENT")).unwrap_or_default();
let generation = current.trim().to_string();
let source_digest = {
use sha2::{Digest, Sha256};
let mut h = Sha256::new();
for a in &semantic.semantics.artifacts {
h.update(a.hashes.artifact.0.as_bytes());
}
format!("sha256:{:x}", h.finalize())
};
let evidence_digest = {
use sha2::{Digest, Sha256};
let mut h = Sha256::new();
for a in &semantic.semantics.artifacts {
h.update(a.hashes.evidence.0.as_bytes());
}
format!("sha256:{:x}", h.finalize())
};
let manifest = json!({
"schema_version": 1,
"kind": "publish_manifest",
"semantic_generation": generation,
"retrieval": {
"ekc_graph": "ekc/graph",
"modules": graph.modules.len(),
"symbols": graph.symbols.len(),
"capabilities": graph.capabilities.len(),
"knowledge": graph.knowledge.len(),
},
"source_digest": source_digest,
"evidence_digest": evidence_digest,
"excluded_dirs": crate::project::EXCLUDED_DIRS,
"project_id": semantic.semantics.project_id,
});
let path = out_dir.join("publish_manifest.json");
fs::write(&path, serde_json::to_string_pretty(&manifest)?)
.with_context(|| format!("write {}", path.display()))?;
Ok(())
}
/// Directory for the legacy EKC retrieval projection (not execution authority).
pub fn ekc_graph_dir(out_dir: &Path) -> std::path::PathBuf {
out_dir.join("ekc").join("graph")
+2 -14
View File
@@ -164,13 +164,7 @@ fn collect_mq_md(
let p = entry.path();
if p.is_dir() {
let name = p.file_name().and_then(|s| s.to_str()).unwrap_or("");
if name == "target"
|| name == ".git"
|| name == "node_modules"
|| name == "docker"
|| name == "data"
|| name == ".cursor"
{
if crate::project::is_excluded_dir_name(name) {
continue;
}
if let Ok(canon) = p.canonicalize() {
@@ -210,13 +204,7 @@ fn walk_knowledge_md(
let p = entry.path();
if p.is_dir() {
let name = p.file_name().and_then(|s| s.to_str()).unwrap_or("");
if name == "target"
|| name == ".git"
|| name == ".marqdo"
|| name == "docker"
|| name == "data"
|| name == ".cursor"
{
if crate::project::is_excluded_dir_name(name) {
continue;
}
if let Ok(canon) = p.canonicalize() {