Skip to content

Commit 828fa6b

Browse files
committed
chore: restructure nested 6a2ml files into .machine_readable/6a2/
1 parent a3b4a47 commit 828fa6b

4 files changed

Lines changed: 1926 additions & 0 deletions

File tree

verisimdb/schema/clade.vql

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
-- SPDX-License-Identifier: PMPL-1.0-or-later
2+
-- VQL schema: Clade definition octad
3+
4+
DEFINE SCHEMA clade VERSION 1.0.0;
5+
6+
DEFINE GRAPH clade {
7+
members: [UUID], -- repos in this clade (primary membership)
8+
secondary_members: [UUID], -- repos with secondary membership
9+
related_clades: [{ -- inter-clade relationships
10+
clade: STRING(2),
11+
relationship: ENUM("depends_on", "feeds_into", "shares_infra", "overlaps")
12+
}]
13+
};
14+
15+
DEFINE TENSOR clade {
16+
member_count: INT,
17+
avg_completion: FLOAT,
18+
active_count: INT,
19+
stale_count: INT
20+
} TEMPORAL;
21+
22+
DEFINE SEMANTIC clade {
23+
type: ENUM("clade"),
24+
code: STRING(2),
25+
name: STRING,
26+
description: TEXT,
27+
colour: STRING,
28+
icon: STRING,
29+
keywords: [STRING]
30+
};
31+
32+
DEFINE DOCUMENT clade {
33+
title: STRING,
34+
description: TEXT,
35+
health_report: TEXT? -- generated health summary
36+
} INDEXED;
37+
38+
DEFINE TEMPORAL clade {
39+
created: TIMESTAMP,
40+
last_member_change: TIMESTAMP,
41+
last_health_check: TIMESTAMP?
42+
};
43+
44+
DEFINE PROVENANCE clade {
45+
creator: STRING,
46+
last_modifier: STRING
47+
};

verisimdb/schema/repo.vql

Lines changed: 99 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,99 @@
1+
-- SPDX-License-Identifier: PMPL-1.0-or-later
2+
-- VQL schema: Repository octad
3+
-- Each repository is an 8-modality entity in VeriSimDB
4+
5+
DEFINE SCHEMA repo VERSION 1.0.0;
6+
7+
-- Graph modality: relationships between repos
8+
DEFINE GRAPH repo {
9+
depends_on: [UUID], -- repos this depends on
10+
depended_by: [UUID], -- repos depending on this
11+
clade_edge: UUID, -- link to clade octad
12+
monorepo_parent: UUID?, -- parent monorepo (if child)
13+
monorepo_children: [UUID], -- children (if monorepo)
14+
forge_links: { -- primary + foreign key links
15+
github: STRING,
16+
gitlab: STRING?,
17+
bitbucket: STRING?,
18+
codeberg: STRING?,
19+
sourcehut: STRING?,
20+
radicle: STRING?
21+
},
22+
tags: [STRING] -- free-form tags
23+
};
24+
25+
-- Vector modality: semantic embedding for similarity search
26+
DEFINE VECTOR repo {
27+
purpose_embedding: FLOAT[384], -- sentence-transformer embedding of description
28+
tech_embedding: FLOAT[384] -- embedding of technology stack
29+
};
30+
31+
-- Tensor modality: numeric metrics over time
32+
DEFINE TENSOR repo {
33+
completion: FLOAT, -- 0.0 to 100.0
34+
loc: INT, -- lines of code
35+
test_count: INT, -- number of tests
36+
open_issues: INT, -- open issue count
37+
dependency_count: INT -- direct dependencies
38+
} TEMPORAL; -- time-series tracking enabled
39+
40+
-- Semantic modality: typed metadata
41+
DEFINE SEMANTIC repo {
42+
type: ENUM("repo"),
43+
clade_primary: STRING(2), -- 2-char clade code
44+
clade_secondary: [STRING(2)],
45+
license: STRING, -- SPDX identifier
46+
languages: [STRING], -- programming languages used
47+
version: STRING?, -- current version if applicable
48+
status: ENUM("active", "stale", "archived", "experimental", "complete"),
49+
lineage_type: ENUM("standalone", "monorepo", "monorepo-child", "inflated", "deflated")
50+
};
51+
52+
-- Document modality: full-text searchable content
53+
DEFINE DOCUMENT repo {
54+
title: STRING, -- display name
55+
description: TEXT, -- one-line description
56+
readme_summary: TEXT?, -- first section of README
57+
setup_instructions: TEXT?, -- extracted setup/install docs
58+
changelog_latest: TEXT?, -- latest changelog entry
59+
state_body: TEXT? -- STATE.a2ml content cache
60+
} INDEXED; -- full-text search enabled
61+
62+
-- Temporal modality: time tracking
63+
DEFINE TEMPORAL repo {
64+
created: TIMESTAMP, -- repo creation date
65+
last_commit: TIMESTAMP?, -- most recent git commit
66+
last_state_change: TIMESTAMP?,-- last meaningful state update
67+
last_activity: TIMESTAMP, -- max(commit, state_change, bot_finding)
68+
sessions: [{ -- work sessions
69+
id: STRING,
70+
started: TIMESTAMP,
71+
ended: TIMESTAMP?,
72+
agent: STRING -- "claude-code", "jonathan", etc.
73+
}]
74+
};
75+
76+
-- Provenance modality: origin and authority tracking
77+
DEFINE PROVENANCE repo {
78+
creator: STRING, -- who created the repo
79+
last_modifier: STRING, -- who last changed state
80+
authority_pointers: [{ -- pointer authority system
81+
field: STRING, -- which field
82+
type: ENUM("pointer", "local", "derived"),
83+
source: STRING?, -- external source path (if pointer)
84+
hash: STRING?, -- SHA-256 of cached value
85+
synced_at: TIMESTAMP?
86+
}],
87+
attestations: [{ -- signed attestations
88+
claim: STRING,
89+
signer: STRING,
90+
signature: STRING,
91+
timestamp: TIMESTAMP
92+
}]
93+
};
94+
95+
-- Spatial modality: reserved for future use
96+
DEFINE SPATIAL repo {
97+
org_x: FLOAT?, -- position in org hierarchy visualisation
98+
org_y: FLOAT?
99+
};

verisimdb/schema/todo.vql

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
-- SPDX-License-Identifier: PMPL-1.0-or-later
2+
-- VQL schema: Work item / TODO octad
3+
-- Replaces scattered memory files, queue dumps, and bot logs
4+
5+
DEFINE SCHEMA todo VERSION 1.0.0;
6+
7+
DEFINE GRAPH todo {
8+
repo: UUID?, -- associated repo (if any)
9+
clade: STRING(2)?, -- associated clade (if any)
10+
blocks: [UUID], -- TODOs this blocks
11+
blocked_by: [UUID], -- TODOs blocking this
12+
resulted_from: UUID?, -- feedback/observation that spawned this
13+
resulted_in: UUID? -- commit/PR that resolved this
14+
};
15+
16+
DEFINE TENSOR todo {
17+
priority: INT, -- 0 = P0 (highest), 7 = P7 (lowest)
18+
effort_estimate: INT?, -- estimated hours (optional)
19+
progress: FLOAT -- 0.0 to 1.0
20+
} TEMPORAL;
21+
22+
DEFINE SEMANTIC todo {
23+
type: ENUM("todo"),
24+
category: ENUM("bug", "feature", "refactor", "docs", "security", "infra", "governance", "research"),
25+
status: ENUM("open", "in_progress", "blocked", "done", "wontfix", "superseded"),
26+
source: ENUM("human", "bot", "agent", "ci")
27+
};
28+
29+
DEFINE DOCUMENT todo {
30+
title: STRING,
31+
body: TEXT,
32+
resolution: TEXT? -- how it was resolved (if done)
33+
} INDEXED;
34+
35+
DEFINE TEMPORAL todo {
36+
created: TIMESTAMP,
37+
updated: TIMESTAMP,
38+
due: TIMESTAMP?,
39+
started: TIMESTAMP?,
40+
completed: TIMESTAMP?,
41+
acknowledged: TIMESTAMP? -- when someone first saw this
42+
};
43+
44+
DEFINE PROVENANCE todo {
45+
creator: STRING, -- who/what created it
46+
creator_type: ENUM("human", "bot", "agent"),
47+
assignee: STRING?,
48+
session_id: STRING?, -- which session created it
49+
authority_pointers: [{
50+
field: STRING,
51+
type: ENUM("pointer", "local", "derived"),
52+
source: STRING?,
53+
hash: STRING?,
54+
synced_at: TIMESTAMP?
55+
}]
56+
};

0 commit comments

Comments
 (0)