htm 0.0.2 → 0.0.11
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.
- checksums.yaml +4 -4
- data/.aigcm_msg +1 -0
- data/.architecture/reviews/comprehensive-codebase-review.md +577 -0
- data/.claude/settings.local.json +95 -0
- data/.irbrc +283 -80
- data/.tbls.yml +2 -1
- data/CHANGELOG.md +327 -26
- data/CLAUDE.md +603 -0
- data/README.md +83 -12
- data/Rakefile +5 -0
- data/bin/htm_mcp.rb +527 -0
- data/db/migrate/{20250101000001_enable_extensions.rb → 00001_enable_extensions.rb} +0 -1
- data/db/migrate/00002_create_robots.rb +11 -0
- data/db/migrate/00003_create_file_sources.rb +20 -0
- data/db/migrate/00004_create_nodes.rb +65 -0
- data/db/migrate/00005_create_tags.rb +13 -0
- data/db/migrate/00006_create_node_tags.rb +18 -0
- data/db/migrate/00007_create_robot_nodes.rb +26 -0
- data/db/migrate/00009_add_working_memory_to_robot_nodes.rb +12 -0
- data/db/schema.sql +172 -1
- data/docs/api/database.md +1 -2
- data/docs/api/htm.md +197 -2
- data/docs/api/yard/HTM/ActiveRecordConfig.md +23 -0
- data/docs/api/yard/HTM/AuthorizationError.md +11 -0
- data/docs/api/yard/HTM/CircuitBreaker.md +92 -0
- data/docs/api/yard/HTM/CircuitBreakerOpenError.md +34 -0
- data/docs/api/yard/HTM/Configuration.md +175 -0
- data/docs/api/yard/HTM/Database.md +99 -0
- data/docs/api/yard/HTM/DatabaseError.md +14 -0
- data/docs/api/yard/HTM/EmbeddingError.md +18 -0
- data/docs/api/yard/HTM/EmbeddingService.md +58 -0
- data/docs/api/yard/HTM/Error.md +11 -0
- data/docs/api/yard/HTM/JobAdapter.md +39 -0
- data/docs/api/yard/HTM/LongTermMemory.md +342 -0
- data/docs/api/yard/HTM/NotFoundError.md +17 -0
- data/docs/api/yard/HTM/Observability.md +107 -0
- data/docs/api/yard/HTM/QueryTimeoutError.md +19 -0
- data/docs/api/yard/HTM/Railtie.md +27 -0
- data/docs/api/yard/HTM/ResourceExhaustedError.md +13 -0
- data/docs/api/yard/HTM/TagError.md +18 -0
- data/docs/api/yard/HTM/TagService.md +67 -0
- data/docs/api/yard/HTM/Timeframe/Result.md +24 -0
- data/docs/api/yard/HTM/Timeframe.md +40 -0
- data/docs/api/yard/HTM/TimeframeExtractor/Result.md +24 -0
- data/docs/api/yard/HTM/TimeframeExtractor.md +45 -0
- data/docs/api/yard/HTM/ValidationError.md +20 -0
- data/docs/api/yard/HTM/WorkingMemory.md +131 -0
- data/docs/api/yard/HTM.md +80 -0
- data/docs/api/yard/index.csv +179 -0
- data/docs/api/yard-reference.md +51 -0
- data/docs/database/README.md +128 -128
- data/docs/database/public.file_sources.md +42 -0
- data/docs/database/public.file_sources.svg +211 -0
- data/docs/database/public.node_tags.md +4 -4
- data/docs/database/public.node_tags.svg +212 -79
- data/docs/database/public.nodes.md +22 -12
- data/docs/database/public.nodes.svg +246 -127
- data/docs/database/public.robot_nodes.md +11 -9
- data/docs/database/public.robot_nodes.svg +220 -98
- data/docs/database/public.robots.md +2 -2
- data/docs/database/public.robots.svg +136 -81
- data/docs/database/public.tags.md +3 -3
- data/docs/database/public.tags.svg +118 -39
- data/docs/database/schema.json +850 -771
- data/docs/database/schema.svg +256 -197
- data/docs/development/schema.md +67 -2
- data/docs/guides/adding-memories.md +93 -7
- data/docs/guides/recalling-memories.md +36 -1
- data/examples/README.md +405 -0
- data/examples/cli_app/htm_cli.rb +65 -5
- data/examples/cli_app/temp.log +93 -0
- data/examples/file_loader_usage.rb +177 -0
- data/examples/mcp_client.rb +529 -0
- data/examples/robot_groups/lib/robot_group.rb +419 -0
- data/examples/robot_groups/lib/working_memory_channel.rb +140 -0
- data/examples/robot_groups/multi_process.rb +286 -0
- data/examples/robot_groups/robot_worker.rb +136 -0
- data/examples/robot_groups/same_process.rb +229 -0
- data/examples/timeframe_demo.rb +276 -0
- data/lib/htm/active_record_config.rb +1 -1
- data/lib/htm/circuit_breaker.rb +202 -0
- data/lib/htm/configuration.rb +59 -13
- data/lib/htm/database.rb +67 -36
- data/lib/htm/embedding_service.rb +39 -2
- data/lib/htm/errors.rb +131 -11
- data/lib/htm/jobs/generate_embedding_job.rb +5 -4
- data/lib/htm/jobs/generate_tags_job.rb +4 -0
- data/lib/htm/loaders/markdown_loader.rb +263 -0
- data/lib/htm/loaders/paragraph_chunker.rb +112 -0
- data/lib/htm/long_term_memory.rb +460 -343
- data/lib/htm/models/file_source.rb +99 -0
- data/lib/htm/models/node.rb +80 -5
- data/lib/htm/models/robot.rb +24 -1
- data/lib/htm/models/robot_node.rb +1 -0
- data/lib/htm/models/tag.rb +254 -4
- data/lib/htm/observability.rb +395 -0
- data/lib/htm/tag_service.rb +60 -3
- data/lib/htm/tasks.rb +26 -1
- data/lib/htm/timeframe.rb +194 -0
- data/lib/htm/timeframe_extractor.rb +307 -0
- data/lib/htm/version.rb +1 -1
- data/lib/htm/working_memory.rb +165 -70
- data/lib/htm.rb +328 -130
- data/lib/tasks/doc.rake +300 -0
- data/lib/tasks/files.rake +299 -0
- data/lib/tasks/htm.rake +158 -3
- data/lib/tasks/jobs.rake +3 -9
- data/lib/tasks/tags.rake +166 -6
- data/mkdocs.yml +36 -1
- data/notes/ARCHITECTURE_REVIEW.md +1167 -0
- data/notes/IMPLEMENTATION_SUMMARY.md +606 -0
- data/notes/MULTI_FRAMEWORK_IMPLEMENTATION.md +451 -0
- data/notes/next_steps.md +100 -0
- data/notes/plan.md +627 -0
- data/notes/tag_ontology_enhancement_ideas.md +222 -0
- data/notes/timescaledb_removal_summary.md +200 -0
- metadata +158 -17
- data/db/migrate/20250101000002_create_robots.rb +0 -14
- data/db/migrate/20250101000003_create_nodes.rb +0 -42
- data/db/migrate/20250101000005_create_tags.rb +0 -38
- data/db/migrate/20250101000007_add_node_vector_indexes.rb +0 -30
- data/db/migrate/20250125000001_add_content_hash_to_nodes.rb +0 -14
- data/db/migrate/20250125000002_create_robot_nodes.rb +0 -35
- data/db/migrate/20250125000003_remove_source_and_robot_id_from_nodes.rb +0 -28
- data/db/migrate/20250126000001_create_working_memories.rb +0 -19
- data/db/migrate/20250126000002_remove_unused_columns.rb +0 -12
- data/docs/database/public.working_memories.md +0 -40
- data/docs/database/public.working_memories.svg +0 -112
- data/lib/htm/models/working_memory_entry.rb +0 -88
data/docs/database/schema.svg
CHANGED
|
@@ -4,220 +4,279 @@
|
|
|
4
4
|
<!-- Generated by graphviz version 12.1.2 (20240928.0832)
|
|
5
5
|
-->
|
|
6
6
|
<!-- Title: htm_development Pages: 1 -->
|
|
7
|
-
<svg width="
|
|
8
|
-
viewBox="0.00 0.00
|
|
9
|
-
<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4
|
|
7
|
+
<svg width="2221pt" height="1463pt"
|
|
8
|
+
viewBox="0.00 0.00 2220.69 1462.80" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
|
9
|
+
<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 1458.8)">
|
|
10
10
|
<title>htm_development</title>
|
|
11
|
-
<polygon fill="white" stroke="none" points="-4,4 -4,-
|
|
12
|
-
<!-- public.
|
|
11
|
+
<polygon fill="white" stroke="none" points="-4,4 -4,-1458.8 2216.69,-1458.8 2216.69,4 -4,4"/>
|
|
12
|
+
<!-- public.file_sources -->
|
|
13
13
|
<g id="node1" class="node">
|
|
14
|
-
<title>public.
|
|
15
|
-
<polygon fill="#efefef" stroke="none" points="
|
|
16
|
-
<polygon fill="none" stroke="black" points="
|
|
17
|
-
<text text-anchor="start" x="
|
|
18
|
-
<text text-anchor="start" x="
|
|
19
|
-
<text text-anchor="start" x="
|
|
20
|
-
<
|
|
21
|
-
<
|
|
22
|
-
<text text-anchor="start" x="
|
|
23
|
-
<
|
|
24
|
-
<
|
|
25
|
-
<text text-anchor="start" x="
|
|
26
|
-
<
|
|
27
|
-
<text text-anchor="start" x="
|
|
28
|
-
<
|
|
29
|
-
<
|
|
30
|
-
<text text-anchor="start" x="
|
|
31
|
-
<text text-anchor="start" x="
|
|
32
|
-
<polygon fill="none" stroke="black" points="
|
|
33
|
-
<text text-anchor="start" x="
|
|
34
|
-
<text text-anchor="start" x="
|
|
35
|
-
<
|
|
36
|
-
<
|
|
37
|
-
<text text-anchor="start" x="
|
|
38
|
-
<
|
|
39
|
-
<text text-anchor="start" x="
|
|
40
|
-
<
|
|
41
|
-
<
|
|
42
|
-
<text text-anchor="start" x="
|
|
43
|
-
<
|
|
14
|
+
<title>public.file_sources</title>
|
|
15
|
+
<polygon fill="#efefef" stroke="none" points="834.64,-320.4 834.64,-366.4 1326.38,-366.4 1326.38,-320.4 834.64,-320.4"/>
|
|
16
|
+
<polygon fill="none" stroke="black" points="834.64,-320.4 834.64,-366.4 1326.38,-366.4 1326.38,-320.4 834.64,-320.4"/>
|
|
17
|
+
<text text-anchor="start" x="950.04" y="-344.2" font-family="Arial Bold" font-size="18.00">public.file_sources</text>
|
|
18
|
+
<text text-anchor="start" x="1086.5" y="-344.2" font-family="Arial" font-size="14.00"> </text>
|
|
19
|
+
<text text-anchor="start" x="1117.61" y="-344.2" font-family="Arial" font-size="14.00" fill="#666666">[BASE TABLE]</text>
|
|
20
|
+
<text text-anchor="start" x="947.04" y="-329.8" font-family="Arial" font-size="14.00" fill="#333333">Source file metadata for loaded documents</text>
|
|
21
|
+
<polygon fill="none" stroke="black" points="834.64,-289.6 834.64,-320.4 1326.38,-320.4 1326.38,-289.6 834.64,-289.6"/>
|
|
22
|
+
<text text-anchor="start" x="841.64" y="-301.8" font-family="Arial" font-size="14.00">created_at </text>
|
|
23
|
+
<text text-anchor="start" x="911.69" y="-301.8" font-family="Arial" font-size="14.00" fill="#666666">[timestamp with time zone]</text>
|
|
24
|
+
<polygon fill="none" stroke="black" points="834.64,-258.8 834.64,-289.6 1326.38,-289.6 1326.38,-258.8 834.64,-258.8"/>
|
|
25
|
+
<text text-anchor="start" x="841.64" y="-271" font-family="Arial" font-size="14.00">file_hash </text>
|
|
26
|
+
<text text-anchor="start" x="901.57" y="-271" font-family="Arial" font-size="14.00" fill="#666666">[varchar(64)]</text>
|
|
27
|
+
<text text-anchor="start" x="980.93" y="-271" font-family="Arial" font-size="14.00"> SHA-256 hash of file content</text>
|
|
28
|
+
<polygon fill="none" stroke="black" points="834.64,-228 834.64,-258.8 1326.38,-258.8 1326.38,-228 834.64,-228"/>
|
|
29
|
+
<text text-anchor="start" x="841.64" y="-240.2" font-family="Arial" font-size="14.00">file_path </text>
|
|
30
|
+
<text text-anchor="start" x="898.46" y="-240.2" font-family="Arial" font-size="14.00" fill="#666666">[text]</text>
|
|
31
|
+
<text text-anchor="start" x="928.81" y="-240.2" font-family="Arial" font-size="14.00"> Absolute path to source file</text>
|
|
32
|
+
<polygon fill="none" stroke="black" points="834.64,-197.2 834.64,-228 1326.38,-228 1326.38,-197.2 834.64,-197.2"/>
|
|
33
|
+
<text text-anchor="start" x="841.64" y="-209.4" font-family="Arial" font-size="14.00">file_size </text>
|
|
34
|
+
<text text-anchor="start" x="896.11" y="-209.4" font-family="Arial" font-size="14.00" fill="#666666">[integer]</text>
|
|
35
|
+
<text text-anchor="start" x="946.7" y="-209.4" font-family="Arial" font-size="14.00"> File size in bytes</text>
|
|
36
|
+
<polygon fill="none" stroke="black" points="834.64,-166.4 834.64,-197.2 1326.38,-197.2 1326.38,-166.4 834.64,-166.4"/>
|
|
37
|
+
<text text-anchor="start" x="841.64" y="-178.6" font-family="Arial" font-size="14.00">frontmatter </text>
|
|
38
|
+
<text text-anchor="start" x="913.22" y="-178.6" font-family="Arial" font-size="14.00" fill="#666666">[jsonb]</text>
|
|
39
|
+
<text text-anchor="start" x="954.47" y="-178.6" font-family="Arial" font-size="14.00"> Parsed YAML frontmatter</text>
|
|
40
|
+
<polygon fill="none" stroke="black" points="834.64,-135.6 834.64,-166.4 1326.38,-166.4 1326.38,-135.6 834.64,-135.6"/>
|
|
41
|
+
<text text-anchor="start" x="841.64" y="-147.8" font-family="Arial" font-size="14.00">id </text>
|
|
42
|
+
<text text-anchor="start" x="856.43" y="-147.8" font-family="Arial" font-size="14.00" fill="#666666">[bigint]</text>
|
|
43
|
+
<polygon fill="none" stroke="black" points="834.64,-104.8 834.64,-135.6 1326.38,-135.6 1326.38,-104.8 834.64,-104.8"/>
|
|
44
|
+
<text text-anchor="start" x="841.64" y="-117" font-family="Arial" font-size="14.00">last_synced_at </text>
|
|
45
|
+
<text text-anchor="start" x="938.92" y="-117" font-family="Arial" font-size="14.00" fill="#666666">[timestamp with time zone]</text>
|
|
46
|
+
<text text-anchor="start" x="1104.65" y="-117" font-family="Arial" font-size="14.00"> When file was last synced to HTM</text>
|
|
47
|
+
<polygon fill="none" stroke="black" points="834.64,-74 834.64,-104.8 1326.38,-104.8 1326.38,-74 834.64,-74"/>
|
|
48
|
+
<text text-anchor="start" x="841.64" y="-86.2" font-family="Arial" font-size="14.00">mtime </text>
|
|
49
|
+
<text text-anchor="start" x="883.64" y="-86.2" font-family="Arial" font-size="14.00" fill="#666666">[timestamp with time zone]</text>
|
|
50
|
+
<text text-anchor="start" x="1049.36" y="-86.2" font-family="Arial" font-size="14.00"> File modification time</text>
|
|
51
|
+
<polygon fill="none" stroke="black" points="834.64,-43.2 834.64,-74 1326.38,-74 1326.38,-43.2 834.64,-43.2"/>
|
|
52
|
+
<text text-anchor="start" x="841.64" y="-55.4" font-family="Arial" font-size="14.00">updated_at </text>
|
|
53
|
+
<text text-anchor="start" x="915.6" y="-55.4" font-family="Arial" font-size="14.00" fill="#666666">[timestamp with time zone]</text>
|
|
44
54
|
</g>
|
|
45
|
-
<!-- public.
|
|
46
|
-
<g id="
|
|
47
|
-
<title>public.
|
|
48
|
-
<polygon fill="#efefef" stroke="none" points="
|
|
49
|
-
<polygon fill="none" stroke="black" points="
|
|
50
|
-
<text text-anchor="start" x="
|
|
51
|
-
<text text-anchor="start" x="
|
|
52
|
-
<text text-anchor="start" x="
|
|
53
|
-
<
|
|
54
|
-
<
|
|
55
|
-
<text text-anchor="start" x="
|
|
56
|
-
<
|
|
57
|
-
<text text-anchor="start" x="
|
|
58
|
-
<
|
|
59
|
-
<
|
|
60
|
-
<text text-anchor="start" x="
|
|
61
|
-
<
|
|
62
|
-
<
|
|
63
|
-
<text text-anchor="start" x="
|
|
64
|
-
<text text-anchor="start" x="
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
<
|
|
68
|
-
<
|
|
69
|
-
<path fill="none" stroke="black" d="M464.7,-706.99C421.57,-684.81 435.26,-516.18 423.18,-466 399.18,-366.37 465.54,-243.4 363.06,-243.4"/>
|
|
70
|
-
<polygon fill="black" stroke="black" points="464.74,-707 473.42,-713.7 469.93,-708.24 474.14,-709.24 474.14,-709.24 474.14,-709.24 469.93,-708.24 475.51,-704.95 464.74,-707"/>
|
|
71
|
-
<text text-anchor="start" x="481.79" y="-719.4" font-family="Arial" font-size="10.00">FOREIGN KEY (robot_id) REFERENCES robots(id) ON DELETE CASCADE</text>
|
|
55
|
+
<!-- public.node_tags -->
|
|
56
|
+
<g id="node2" class="node">
|
|
57
|
+
<title>public.node_tags</title>
|
|
58
|
+
<polygon fill="#efefef" stroke="none" points="493.91,-1288.6 493.91,-1334.6 963.12,-1334.6 963.12,-1288.6 493.91,-1288.6"/>
|
|
59
|
+
<polygon fill="none" stroke="black" points="493.91,-1288.6 493.91,-1334.6 963.12,-1334.6 963.12,-1288.6 493.91,-1288.6"/>
|
|
60
|
+
<text text-anchor="start" x="605.03" y="-1312.4" font-family="Arial Bold" font-size="18.00">public.node_tags</text>
|
|
61
|
+
<text text-anchor="start" x="727.51" y="-1312.4" font-family="Arial" font-size="14.00"> </text>
|
|
62
|
+
<text text-anchor="start" x="758.62" y="-1312.4" font-family="Arial" font-size="14.00" fill="#666666">[BASE TABLE]</text>
|
|
63
|
+
<text text-anchor="start" x="567.43" y="-1298" font-family="Arial" font-size="14.00" fill="#333333">Join table connecting nodes to tags (many-to-many)</text>
|
|
64
|
+
<polygon fill="none" stroke="black" points="493.91,-1257.8 493.91,-1288.6 963.12,-1288.6 963.12,-1257.8 493.91,-1257.8"/>
|
|
65
|
+
<text text-anchor="start" x="500.91" y="-1270" font-family="Arial" font-size="14.00">created_at </text>
|
|
66
|
+
<text text-anchor="start" x="570.95" y="-1270" font-family="Arial" font-size="14.00" fill="#666666">[timestamp with time zone]</text>
|
|
67
|
+
<text text-anchor="start" x="736.68" y="-1270" font-family="Arial" font-size="14.00"> When this association was created</text>
|
|
68
|
+
<polygon fill="none" stroke="black" points="493.91,-1227 493.91,-1257.8 963.12,-1257.8 963.12,-1227 493.91,-1227"/>
|
|
69
|
+
<text text-anchor="start" x="500.91" y="-1239.2" font-family="Arial" font-size="14.00">id </text>
|
|
70
|
+
<text text-anchor="start" x="515.69" y="-1239.2" font-family="Arial" font-size="14.00" fill="#666666">[bigint]</text>
|
|
71
|
+
<polygon fill="none" stroke="black" points="493.91,-1196.2 493.91,-1227 963.12,-1227 963.12,-1196.2 493.91,-1196.2"/>
|
|
72
|
+
<text text-anchor="start" x="500.91" y="-1208.4" font-family="Arial" font-size="14.00">node_id </text>
|
|
73
|
+
<text text-anchor="start" x="554.62" y="-1208.4" font-family="Arial" font-size="14.00" fill="#666666">[bigint]</text>
|
|
74
|
+
<text text-anchor="start" x="595.87" y="-1208.4" font-family="Arial" font-size="14.00"> ID of the node being tagged</text>
|
|
75
|
+
<polygon fill="none" stroke="black" points="493.91,-1165.4 493.91,-1196.2 963.12,-1196.2 963.12,-1165.4 493.91,-1165.4"/>
|
|
76
|
+
<text text-anchor="start" x="500.91" y="-1177.6" font-family="Arial" font-size="14.00">tag_id </text>
|
|
77
|
+
<text text-anchor="start" x="542.94" y="-1177.6" font-family="Arial" font-size="14.00" fill="#666666">[bigint]</text>
|
|
78
|
+
<text text-anchor="start" x="584.19" y="-1177.6" font-family="Arial" font-size="14.00"> ID of the tag being applied</text>
|
|
72
79
|
</g>
|
|
73
80
|
<!-- public.nodes -->
|
|
74
|
-
<g id="
|
|
81
|
+
<g id="node3" class="node">
|
|
75
82
|
<title>public.nodes</title>
|
|
76
|
-
<polygon fill="#efefef" stroke="none" points="
|
|
77
|
-
<polygon fill="none" stroke="black" points="
|
|
78
|
-
<text text-anchor="start" x="
|
|
79
|
-
<text text-anchor="start" x="
|
|
80
|
-
<text text-anchor="start" x="
|
|
81
|
-
<
|
|
82
|
-
<
|
|
83
|
-
<text text-anchor="start" x="
|
|
84
|
-
<
|
|
85
|
-
<text text-anchor="start" x="
|
|
86
|
-
<
|
|
87
|
-
<
|
|
88
|
-
<text text-anchor="start" x="
|
|
89
|
-
<text text-anchor="start" x="
|
|
90
|
-
<polygon fill="none" stroke="black" points="
|
|
91
|
-
<text text-anchor="start" x="
|
|
92
|
-
<text text-anchor="start" x="
|
|
93
|
-
<
|
|
94
|
-
<
|
|
95
|
-
<text text-anchor="start" x="
|
|
96
|
-
<
|
|
97
|
-
<text text-anchor="start" x="
|
|
98
|
-
<
|
|
99
|
-
<
|
|
100
|
-
<text text-anchor="start" x="
|
|
101
|
-
<text text-anchor="start" x="
|
|
102
|
-
<polygon fill="none" stroke="black" points="
|
|
103
|
-
<text text-anchor="start" x="
|
|
104
|
-
<text text-anchor="start" x="
|
|
105
|
-
<
|
|
106
|
-
<
|
|
107
|
-
<text text-anchor="start" x="
|
|
108
|
-
<
|
|
109
|
-
<text text-anchor="start" x="
|
|
110
|
-
<
|
|
83
|
+
<polygon fill="#efefef" stroke="none" points="752.49,-920 752.49,-966 1408.53,-966 1408.53,-920 752.49,-920"/>
|
|
84
|
+
<polygon fill="none" stroke="black" points="752.49,-920 752.49,-966 1408.53,-966 1408.53,-920 752.49,-920"/>
|
|
85
|
+
<text text-anchor="start" x="972.53" y="-943.8" font-family="Arial Bold" font-size="18.00">public.nodes</text>
|
|
86
|
+
<text text-anchor="start" x="1064.01" y="-943.8" font-family="Arial" font-size="14.00"> </text>
|
|
87
|
+
<text text-anchor="start" x="1095.13" y="-943.8" font-family="Arial" font-size="14.00" fill="#666666">[BASE TABLE]</text>
|
|
88
|
+
<text text-anchor="start" x="889.09" y="-929.4" font-family="Arial" font-size="14.00" fill="#333333">Core memory storage for conversation messages and context</text>
|
|
89
|
+
<polygon fill="none" stroke="black" points="752.49,-889.2 752.49,-920 1408.53,-920 1408.53,-889.2 752.49,-889.2"/>
|
|
90
|
+
<text text-anchor="start" x="759.49" y="-901.4" font-family="Arial" font-size="14.00">access_count </text>
|
|
91
|
+
<text text-anchor="start" x="848.99" y="-901.4" font-family="Arial" font-size="14.00" fill="#666666">[integer]</text>
|
|
92
|
+
<text text-anchor="start" x="899.58" y="-901.4" font-family="Arial" font-size="14.00"> Number of times this node has been accessed/retrieved</text>
|
|
93
|
+
<polygon fill="none" stroke="black" points="752.49,-858.4 752.49,-889.2 1408.53,-889.2 1408.53,-858.4 752.49,-858.4"/>
|
|
94
|
+
<text text-anchor="start" x="759.49" y="-870.6" font-family="Arial" font-size="14.00">chunk_position </text>
|
|
95
|
+
<text text-anchor="start" x="856.78" y="-870.6" font-family="Arial" font-size="14.00" fill="#666666">[integer]</text>
|
|
96
|
+
<text text-anchor="start" x="907.37" y="-870.6" font-family="Arial" font-size="14.00"> Position within source file (0-indexed)</text>
|
|
97
|
+
<polygon fill="none" stroke="black" points="752.49,-827.6 752.49,-858.4 1408.53,-858.4 1408.53,-827.6 752.49,-827.6"/>
|
|
98
|
+
<text text-anchor="start" x="759.49" y="-839.8" font-family="Arial" font-size="14.00">content </text>
|
|
99
|
+
<text text-anchor="start" x="809.31" y="-839.8" font-family="Arial" font-size="14.00" fill="#666666">[text]</text>
|
|
100
|
+
<text text-anchor="start" x="839.65" y="-839.8" font-family="Arial" font-size="14.00"> The conversation message/utterance content</text>
|
|
101
|
+
<polygon fill="none" stroke="black" points="752.49,-796.8 752.49,-827.6 1408.53,-827.6 1408.53,-796.8 752.49,-796.8"/>
|
|
102
|
+
<text text-anchor="start" x="759.49" y="-809" font-family="Arial" font-size="14.00">content_hash </text>
|
|
103
|
+
<text text-anchor="start" x="847.45" y="-809" font-family="Arial" font-size="14.00" fill="#666666">[varchar(64)]</text>
|
|
104
|
+
<text text-anchor="start" x="926.81" y="-809" font-family="Arial" font-size="14.00"> SHA-256 hash of content for deduplication</text>
|
|
105
|
+
<polygon fill="none" stroke="black" points="752.49,-766 752.49,-796.8 1408.53,-796.8 1408.53,-766 752.49,-766"/>
|
|
106
|
+
<text text-anchor="start" x="759.49" y="-778.2" font-family="Arial" font-size="14.00">created_at </text>
|
|
107
|
+
<text text-anchor="start" x="829.54" y="-778.2" font-family="Arial" font-size="14.00" fill="#666666">[timestamp with time zone]</text>
|
|
108
|
+
<text text-anchor="start" x="995.26" y="-778.2" font-family="Arial" font-size="14.00"> When this memory was created</text>
|
|
109
|
+
<polygon fill="none" stroke="black" points="752.49,-735.2 752.49,-766 1408.53,-766 1408.53,-735.2 752.49,-735.2"/>
|
|
110
|
+
<text text-anchor="start" x="759.49" y="-747.4" font-family="Arial" font-size="14.00">deleted_at </text>
|
|
111
|
+
<text text-anchor="start" x="828.78" y="-747.4" font-family="Arial" font-size="14.00" fill="#666666">[timestamp with time zone]</text>
|
|
112
|
+
<text text-anchor="start" x="994.5" y="-747.4" font-family="Arial" font-size="14.00"> Soft delete timestamp - node is considered deleted when set</text>
|
|
113
|
+
<polygon fill="none" stroke="black" points="752.49,-704.4 752.49,-735.2 1408.53,-735.2 1408.53,-704.4 752.49,-704.4"/>
|
|
114
|
+
<text text-anchor="start" x="759.49" y="-716.6" font-family="Arial" font-size="14.00">embedding </text>
|
|
115
|
+
<text text-anchor="start" x="832.66" y="-716.6" font-family="Arial" font-size="14.00" fill="#666666">[vector(2000)]</text>
|
|
116
|
+
<text text-anchor="start" x="919.03" y="-716.6" font-family="Arial" font-size="14.00"> Vector embedding (max 2000 dimensions) for semantic search</text>
|
|
117
|
+
<polygon fill="none" stroke="black" points="752.49,-673.6 752.49,-704.4 1408.53,-704.4 1408.53,-673.6 752.49,-673.6"/>
|
|
118
|
+
<text text-anchor="start" x="759.49" y="-685.8" font-family="Arial" font-size="14.00">embedding_dimension </text>
|
|
119
|
+
<text text-anchor="start" x="904.26" y="-685.8" font-family="Arial" font-size="14.00" fill="#666666">[integer]</text>
|
|
120
|
+
<text text-anchor="start" x="954.84" y="-685.8" font-family="Arial" font-size="14.00"> Actual number of dimensions used in the embedding vector (max 2000)</text>
|
|
121
|
+
<polygon fill="none" stroke="black" points="752.49,-642.8 752.49,-673.6 1408.53,-673.6 1408.53,-642.8 752.49,-642.8"/>
|
|
122
|
+
<text text-anchor="start" x="759.49" y="-655" font-family="Arial" font-size="14.00">id </text>
|
|
123
|
+
<text text-anchor="start" x="774.28" y="-655" font-family="Arial" font-size="14.00" fill="#666666">[bigint]</text>
|
|
124
|
+
<polygon fill="none" stroke="black" points="752.49,-612 752.49,-642.8 1408.53,-642.8 1408.53,-612 752.49,-612"/>
|
|
125
|
+
<text text-anchor="start" x="759.49" y="-624.2" font-family="Arial" font-size="14.00">last_accessed </text>
|
|
126
|
+
<text text-anchor="start" x="852.1" y="-624.2" font-family="Arial" font-size="14.00" fill="#666666">[timestamp with time zone]</text>
|
|
127
|
+
<text text-anchor="start" x="1017.82" y="-624.2" font-family="Arial" font-size="14.00"> When this memory was last accessed</text>
|
|
128
|
+
<polygon fill="none" stroke="black" points="752.49,-581.2 752.49,-612 1408.53,-612 1408.53,-581.2 752.49,-581.2"/>
|
|
129
|
+
<text text-anchor="start" x="759.49" y="-593.4" font-family="Arial" font-size="14.00">metadata </text>
|
|
130
|
+
<text text-anchor="start" x="821.76" y="-593.4" font-family="Arial" font-size="14.00" fill="#666666">[jsonb]</text>
|
|
131
|
+
<text text-anchor="start" x="863" y="-593.4" font-family="Arial" font-size="14.00"> Flexible metadata storage (memory_type, importance, source, etc.)</text>
|
|
132
|
+
<polygon fill="none" stroke="black" points="752.49,-550.4 752.49,-581.2 1408.53,-581.2 1408.53,-550.4 752.49,-550.4"/>
|
|
133
|
+
<text text-anchor="start" x="759.49" y="-562.6" font-family="Arial" font-size="14.00">source_id </text>
|
|
134
|
+
<text text-anchor="start" x="824.09" y="-562.6" font-family="Arial" font-size="14.00" fill="#666666">[bigint]</text>
|
|
135
|
+
<text text-anchor="start" x="865.33" y="-562.6" font-family="Arial" font-size="14.00"> Reference to source file (for file-loaded nodes)</text>
|
|
136
|
+
<polygon fill="none" stroke="black" points="752.49,-519.6 752.49,-550.4 1408.53,-550.4 1408.53,-519.6 752.49,-519.6"/>
|
|
137
|
+
<text text-anchor="start" x="759.49" y="-531.8" font-family="Arial" font-size="14.00">token_count </text>
|
|
138
|
+
<text text-anchor="start" x="839.67" y="-531.8" font-family="Arial" font-size="14.00" fill="#666666">[integer]</text>
|
|
139
|
+
<text text-anchor="start" x="890.25" y="-531.8" font-family="Arial" font-size="14.00"> Number of tokens in the content (for context budget management)</text>
|
|
140
|
+
<polygon fill="none" stroke="black" points="752.49,-488.8 752.49,-519.6 1408.53,-519.6 1408.53,-488.8 752.49,-488.8"/>
|
|
141
|
+
<text text-anchor="start" x="759.49" y="-501" font-family="Arial" font-size="14.00">updated_at </text>
|
|
142
|
+
<text text-anchor="start" x="833.45" y="-501" font-family="Arial" font-size="14.00" fill="#666666">[timestamp with time zone]</text>
|
|
143
|
+
<text text-anchor="start" x="999.18" y="-501" font-family="Arial" font-size="14.00"> When this memory was last modified</text>
|
|
111
144
|
</g>
|
|
112
|
-
<!-- public.
|
|
113
|
-
<g id="
|
|
114
|
-
<title>public.
|
|
115
|
-
<path fill="none" stroke="black" d="
|
|
116
|
-
<polygon fill="black" stroke="black" points="
|
|
117
|
-
<text text-anchor="start" x="
|
|
118
|
-
</g>
|
|
119
|
-
<!-- public.schema_migrations -->
|
|
120
|
-
<g id="node2" class="node">
|
|
121
|
-
<title>public.schema_migrations</title>
|
|
122
|
-
<polygon fill="#efefef" stroke="none" points="1258.2,-647.8 1258.2,-683.4 1586.15,-683.4 1586.15,-647.8 1258.2,-647.8"/>
|
|
123
|
-
<polygon fill="none" stroke="black" points="1258.2,-647.8 1258.2,-683.4 1586.15,-683.4 1586.15,-647.8 1258.2,-647.8"/>
|
|
124
|
-
<text text-anchor="start" x="1265.2" y="-661.2" font-family="Arial Bold" font-size="18.00">public.schema_migrations</text>
|
|
125
|
-
<text text-anchor="start" x="1454.66" y="-661.2" font-family="Arial" font-size="14.00"> </text>
|
|
126
|
-
<text text-anchor="start" x="1485.78" y="-661.2" font-family="Arial" font-size="14.00" fill="#666666">[BASE TABLE]</text>
|
|
127
|
-
<polygon fill="none" stroke="black" points="1258.2,-617 1258.2,-647.8 1586.15,-647.8 1586.15,-617 1258.2,-617"/>
|
|
128
|
-
<text text-anchor="start" x="1265.2" y="-629.2" font-family="Arial" font-size="14.00">version </text>
|
|
129
|
-
<text text-anchor="start" x="1314.22" y="-629.2" font-family="Arial" font-size="14.00" fill="#666666">[varchar]</text>
|
|
145
|
+
<!-- public.node_tags->public.nodes -->
|
|
146
|
+
<g id="edge1" class="edge">
|
|
147
|
+
<title>public.node_tags:node_id->public.nodes:id</title>
|
|
148
|
+
<path fill="none" stroke="black" d="M974.1,-1210.09C999.92,-1200.98 981.7,-1152.86 963.12,-1122.2 908.07,-1031.35 807.17,-1100.28 752.49,-1009.2 712.35,-942.32 673.49,-658.2 751.49,-658.2"/>
|
|
149
|
+
<polygon fill="black" stroke="black" points="974.34,-1210.05 963.77,-1207.1 969.06,-1210.85 964.78,-1211.5 964.78,-1211.5 964.78,-1211.5 969.06,-1210.85 965.12,-1216 974.34,-1210.05"/>
|
|
150
|
+
<text text-anchor="start" x="971.12" y="-1221.6" font-family="Arial" font-size="10.00">FOREIGN KEY (node_id) REFERENCES nodes(id) ON DELETE CASCADE</text>
|
|
130
151
|
</g>
|
|
131
152
|
<!-- public.tags -->
|
|
132
|
-
<g id="
|
|
153
|
+
<g id="node7" class="node">
|
|
133
154
|
<title>public.tags</title>
|
|
134
|
-
<polygon fill="#efefef" stroke="none" points="
|
|
135
|
-
<polygon fill="none" stroke="black" points="
|
|
136
|
-
<text text-anchor="start" x="
|
|
137
|
-
<text text-anchor="start" x="
|
|
138
|
-
<text text-anchor="start" x="
|
|
139
|
-
<
|
|
140
|
-
<
|
|
141
|
-
<text text-anchor="start" x="
|
|
142
|
-
<
|
|
143
|
-
<text text-anchor="start" x="
|
|
144
|
-
<
|
|
145
|
-
<
|
|
146
|
-
<text text-anchor="start" x="
|
|
147
|
-
<
|
|
148
|
-
</
|
|
149
|
-
|
|
150
|
-
<
|
|
151
|
-
<title>public.node_tags</title>
|
|
152
|
-
<polygon fill="#efefef" stroke="none" points="892.7,-694 892.7,-729.6 1153.66,-729.6 1153.66,-694 892.7,-694"/>
|
|
153
|
-
<polygon fill="none" stroke="black" points="892.7,-694 892.7,-729.6 1153.66,-729.6 1153.66,-694 892.7,-694"/>
|
|
154
|
-
<text text-anchor="start" x="899.7" y="-707.4" font-family="Arial Bold" font-size="18.00">public.node_tags</text>
|
|
155
|
-
<text text-anchor="start" x="1022.17" y="-707.4" font-family="Arial" font-size="14.00"> </text>
|
|
156
|
-
<text text-anchor="start" x="1053.29" y="-707.4" font-family="Arial" font-size="14.00" fill="#666666">[BASE TABLE]</text>
|
|
157
|
-
<polygon fill="none" stroke="black" points="892.7,-663.2 892.7,-694 1153.66,-694 1153.66,-663.2 892.7,-663.2"/>
|
|
158
|
-
<text text-anchor="start" x="899.7" y="-675.4" font-family="Arial" font-size="14.00">id </text>
|
|
159
|
-
<text text-anchor="start" x="914.48" y="-675.4" font-family="Arial" font-size="14.00" fill="#666666">[bigint]</text>
|
|
160
|
-
<polygon fill="none" stroke="black" points="892.7,-632.4 892.7,-663.2 1153.66,-663.2 1153.66,-632.4 892.7,-632.4"/>
|
|
161
|
-
<text text-anchor="start" x="899.7" y="-644.6" font-family="Arial" font-size="14.00">node_id </text>
|
|
162
|
-
<text text-anchor="start" x="953.41" y="-644.6" font-family="Arial" font-size="14.00" fill="#666666">[bigint]</text>
|
|
163
|
-
<polygon fill="none" stroke="black" points="892.7,-601.6 892.7,-632.4 1153.66,-632.4 1153.66,-601.6 892.7,-601.6"/>
|
|
164
|
-
<text text-anchor="start" x="899.7" y="-613.8" font-family="Arial" font-size="14.00">tag_id </text>
|
|
165
|
-
<text text-anchor="start" x="941.73" y="-613.8" font-family="Arial" font-size="14.00" fill="#666666">[bigint]</text>
|
|
166
|
-
<polygon fill="none" stroke="black" points="892.7,-570.8 892.7,-601.6 1153.66,-601.6 1153.66,-570.8 892.7,-570.8"/>
|
|
167
|
-
<text text-anchor="start" x="899.7" y="-583" font-family="Arial" font-size="14.00">created_at </text>
|
|
168
|
-
<text text-anchor="start" x="969.74" y="-583" font-family="Arial" font-size="14.00" fill="#666666">[timestamp with time zone]</text>
|
|
169
|
-
</g>
|
|
170
|
-
<!-- public.node_tags->public.nodes -->
|
|
171
|
-
<g id="edge3" class="edge">
|
|
172
|
-
<title>public.node_tags:node_id->public.nodes:id</title>
|
|
173
|
-
<path fill="none" stroke="black" d="M881.27,-647.18C813.48,-638.5 871.45,-540.15 841.18,-466 816.2,-404.81 835.43,-335.8 769.34,-335.8"/>
|
|
174
|
-
<polygon fill="black" stroke="black" points="881.38,-647.19 891.09,-652.27 886.7,-647.5 891.03,-647.76 891.03,-647.76 891.03,-647.76 886.7,-647.5 891.63,-643.29 881.38,-647.19"/>
|
|
175
|
-
<text text-anchor="start" x="898.7" y="-657.8" font-family="Arial" font-size="10.00">FOREIGN KEY (node_id) REFERENCES nodes(id) ON DELETE CASCADE</text>
|
|
155
|
+
<polygon fill="#efefef" stroke="none" points="43.2,-750.6 43.2,-796.6 647.83,-796.6 647.83,-750.6 43.2,-750.6"/>
|
|
156
|
+
<polygon fill="none" stroke="black" points="43.2,-750.6 43.2,-796.6 647.83,-796.6 647.83,-750.6 43.2,-750.6"/>
|
|
157
|
+
<text text-anchor="start" x="244.02" y="-774.4" font-family="Arial Bold" font-size="18.00">public.tags</text>
|
|
158
|
+
<text text-anchor="start" x="322.51" y="-774.4" font-family="Arial" font-size="14.00"> </text>
|
|
159
|
+
<text text-anchor="start" x="353.63" y="-774.4" font-family="Arial" font-size="14.00" fill="#666666">[BASE TABLE]</text>
|
|
160
|
+
<text text-anchor="start" x="233.06" y="-760" font-family="Arial" font-size="14.00" fill="#333333">Unique tag names for categorization</text>
|
|
161
|
+
<polygon fill="none" stroke="black" points="43.2,-719.8 43.2,-750.6 647.83,-750.6 647.83,-719.8 43.2,-719.8"/>
|
|
162
|
+
<text text-anchor="start" x="50.2" y="-732" font-family="Arial" font-size="14.00">created_at </text>
|
|
163
|
+
<text text-anchor="start" x="120.25" y="-732" font-family="Arial" font-size="14.00" fill="#666666">[timestamp with time zone]</text>
|
|
164
|
+
<text text-anchor="start" x="285.97" y="-732" font-family="Arial" font-size="14.00"> When this tag was created</text>
|
|
165
|
+
<polygon fill="none" stroke="black" points="43.2,-689 43.2,-719.8 647.83,-719.8 647.83,-689 43.2,-689"/>
|
|
166
|
+
<text text-anchor="start" x="50.2" y="-701.2" font-family="Arial" font-size="14.00">id </text>
|
|
167
|
+
<text text-anchor="start" x="64.99" y="-701.2" font-family="Arial" font-size="14.00" fill="#666666">[bigint]</text>
|
|
168
|
+
<polygon fill="none" stroke="black" points="43.2,-658.2 43.2,-689 647.83,-689 647.83,-658.2 43.2,-658.2"/>
|
|
169
|
+
<text text-anchor="start" x="50.2" y="-670.4" font-family="Arial" font-size="14.00">name </text>
|
|
170
|
+
<text text-anchor="start" x="89.11" y="-670.4" font-family="Arial" font-size="14.00" fill="#666666">[text]</text>
|
|
171
|
+
<text text-anchor="start" x="119.45" y="-670.4" font-family="Arial" font-size="14.00"> Hierarchical tag in format: root:level1:level2 (e.g., database:postgresql:timescaledb)</text>
|
|
176
172
|
</g>
|
|
177
173
|
<!-- public.node_tags->public.tags -->
|
|
178
|
-
<g id="
|
|
174
|
+
<g id="edge2" class="edge">
|
|
179
175
|
<title>public.node_tags:tag_id->public.tags:id</title>
|
|
180
|
-
<path fill="none" stroke="black" d="
|
|
181
|
-
<polygon fill="black" stroke="black" points="
|
|
182
|
-
<text text-anchor="start" x="
|
|
176
|
+
<path fill="none" stroke="black" d="M482.48,-1180.41C289.87,-1165.11 867.91,-704.4 648.83,-704.4"/>
|
|
177
|
+
<polygon fill="black" stroke="black" points="482.58,-1180.41 492.4,-1185.28 487.91,-1180.61 492.24,-1180.78 492.24,-1180.78 492.24,-1180.78 487.91,-1180.61 492.74,-1176.29 482.58,-1180.41"/>
|
|
178
|
+
<text text-anchor="start" x="163.05" y="-1190.8" font-family="Arial" font-size="10.00">FOREIGN KEY (tag_id) REFERENCES tags(id) ON DELETE CASCADE</text>
|
|
183
179
|
</g>
|
|
184
|
-
<!-- public.
|
|
185
|
-
<g id="
|
|
186
|
-
<title>public.
|
|
187
|
-
<
|
|
188
|
-
<polygon fill="
|
|
189
|
-
<text text-anchor="start" x="
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
<
|
|
193
|
-
<
|
|
194
|
-
<
|
|
195
|
-
<polygon fill="none" stroke="black" points="
|
|
196
|
-
<text text-anchor="start" x="
|
|
197
|
-
<text text-anchor="start" x="
|
|
198
|
-
<
|
|
199
|
-
<text text-anchor="start" x="
|
|
200
|
-
<
|
|
201
|
-
<
|
|
202
|
-
<text text-anchor="start" x="
|
|
203
|
-
<
|
|
204
|
-
<
|
|
205
|
-
<text text-anchor="start" x="
|
|
206
|
-
<text text-anchor="start" x="
|
|
180
|
+
<!-- public.nodes->public.file_sources -->
|
|
181
|
+
<g id="edge3" class="edge">
|
|
182
|
+
<title>public.nodes:source_id->public.file_sources:id</title>
|
|
183
|
+
<path fill="none" stroke="black" d="M1419.75,-563.95C1497.06,-534.03 1417.68,-151 1327.38,-151"/>
|
|
184
|
+
<polygon fill="black" stroke="black" points="1419.7,-563.96 1409.06,-561.31 1414.45,-564.91 1410.19,-565.68 1410.19,-565.68 1410.19,-565.68 1414.45,-564.91 1410.66,-570.17 1419.7,-563.96"/>
|
|
185
|
+
<text text-anchor="start" x="1416.53" y="-575.8" font-family="Arial" font-size="10.00">FOREIGN KEY (source_id) REFERENCES file_sources(id) ON DELETE SET NULL</text>
|
|
186
|
+
</g>
|
|
187
|
+
<!-- public.robot_nodes -->
|
|
188
|
+
<g id="node4" class="node">
|
|
189
|
+
<title>public.robot_nodes</title>
|
|
190
|
+
<polygon fill="#efefef" stroke="none" points="1107.77,-1365.6 1107.77,-1411.6 1737.26,-1411.6 1737.26,-1365.6 1107.77,-1365.6"/>
|
|
191
|
+
<polygon fill="none" stroke="black" points="1107.77,-1365.6 1107.77,-1411.6 1737.26,-1411.6 1737.26,-1365.6 1107.77,-1365.6"/>
|
|
192
|
+
<text text-anchor="start" x="1291.03" y="-1389.4" font-family="Arial Bold" font-size="18.00">public.robot_nodes</text>
|
|
193
|
+
<text text-anchor="start" x="1429.51" y="-1389.4" font-family="Arial" font-size="14.00"> </text>
|
|
194
|
+
<text text-anchor="start" x="1460.63" y="-1389.4" font-family="Arial" font-size="14.00" fill="#666666">[BASE TABLE]</text>
|
|
195
|
+
<text text-anchor="start" x="1255.2" y="-1375" font-family="Arial" font-size="14.00" fill="#333333">Join table connecting robots to nodes (many-to-many)</text>
|
|
196
|
+
<polygon fill="none" stroke="black" points="1107.77,-1334.8 1107.77,-1365.6 1737.26,-1365.6 1737.26,-1334.8 1107.77,-1334.8"/>
|
|
197
|
+
<text text-anchor="start" x="1114.77" y="-1347" font-family="Arial" font-size="14.00">created_at </text>
|
|
198
|
+
<text text-anchor="start" x="1184.82" y="-1347" font-family="Arial" font-size="14.00" fill="#666666">[timestamp with time zone]</text>
|
|
199
|
+
<polygon fill="none" stroke="black" points="1107.77,-1304 1107.77,-1334.8 1737.26,-1334.8 1737.26,-1304 1107.77,-1304"/>
|
|
200
|
+
<text text-anchor="start" x="1114.77" y="-1316.2" font-family="Arial" font-size="14.00">first_remembered_at </text>
|
|
201
|
+
<text text-anchor="start" x="1247.82" y="-1316.2" font-family="Arial" font-size="14.00" fill="#666666">[timestamp with time zone]</text>
|
|
202
|
+
<text text-anchor="start" x="1413.55" y="-1316.2" font-family="Arial" font-size="14.00"> When this robot first remembered this content</text>
|
|
203
|
+
<polygon fill="none" stroke="black" points="1107.77,-1273.2 1107.77,-1304 1737.26,-1304 1737.26,-1273.2 1107.77,-1273.2"/>
|
|
204
|
+
<text text-anchor="start" x="1114.77" y="-1285.4" font-family="Arial" font-size="14.00">id </text>
|
|
205
|
+
<text text-anchor="start" x="1129.55" y="-1285.4" font-family="Arial" font-size="14.00" fill="#666666">[bigint]</text>
|
|
206
|
+
<polygon fill="none" stroke="black" points="1107.77,-1242.4 1107.77,-1273.2 1737.26,-1273.2 1737.26,-1242.4 1107.77,-1242.4"/>
|
|
207
|
+
<text text-anchor="start" x="1114.77" y="-1254.6" font-family="Arial" font-size="14.00">last_remembered_at </text>
|
|
208
|
+
<text text-anchor="start" x="1247.06" y="-1254.6" font-family="Arial" font-size="14.00" fill="#666666">[timestamp with time zone]</text>
|
|
209
|
+
<text text-anchor="start" x="1412.78" y="-1254.6" font-family="Arial" font-size="14.00"> When this robot last tried to remember this content</text>
|
|
210
|
+
<polygon fill="none" stroke="black" points="1107.77,-1211.6 1107.77,-1242.4 1737.26,-1242.4 1737.26,-1211.6 1107.77,-1211.6"/>
|
|
211
|
+
<text text-anchor="start" x="1114.77" y="-1223.8" font-family="Arial" font-size="14.00">node_id </text>
|
|
212
|
+
<text text-anchor="start" x="1168.49" y="-1223.8" font-family="Arial" font-size="14.00" fill="#666666">[bigint]</text>
|
|
213
|
+
<text text-anchor="start" x="1209.73" y="-1223.8" font-family="Arial" font-size="14.00"> ID of the node being remembered</text>
|
|
214
|
+
<polygon fill="none" stroke="black" points="1107.77,-1180.8 1107.77,-1211.6 1737.26,-1211.6 1737.26,-1180.8 1107.77,-1180.8"/>
|
|
215
|
+
<text text-anchor="start" x="1114.77" y="-1193" font-family="Arial" font-size="14.00">remember_count </text>
|
|
216
|
+
<text text-anchor="start" x="1224.49" y="-1193" font-family="Arial" font-size="14.00" fill="#666666">[integer]</text>
|
|
217
|
+
<text text-anchor="start" x="1275.07" y="-1193" font-family="Arial" font-size="14.00"> Number of times this robot has tried to remember this content</text>
|
|
218
|
+
<polygon fill="none" stroke="black" points="1107.77,-1150 1107.77,-1180.8 1737.26,-1180.8 1737.26,-1150 1107.77,-1150"/>
|
|
219
|
+
<text text-anchor="start" x="1114.77" y="-1162.2" font-family="Arial" font-size="14.00">robot_id </text>
|
|
220
|
+
<text text-anchor="start" x="1169.25" y="-1162.2" font-family="Arial" font-size="14.00" fill="#666666">[bigint]</text>
|
|
221
|
+
<text text-anchor="start" x="1210.5" y="-1162.2" font-family="Arial" font-size="14.00"> ID of the robot that remembered this node</text>
|
|
222
|
+
<polygon fill="none" stroke="black" points="1107.77,-1119.2 1107.77,-1150 1737.26,-1150 1737.26,-1119.2 1107.77,-1119.2"/>
|
|
223
|
+
<text text-anchor="start" x="1114.77" y="-1131.4" font-family="Arial" font-size="14.00">updated_at </text>
|
|
224
|
+
<text text-anchor="start" x="1188.73" y="-1131.4" font-family="Arial" font-size="14.00" fill="#666666">[timestamp with time zone]</text>
|
|
225
|
+
<polygon fill="none" stroke="black" points="1107.77,-1088.4 1107.77,-1119.2 1737.26,-1119.2 1737.26,-1088.4 1107.77,-1088.4"/>
|
|
226
|
+
<text text-anchor="start" x="1114.77" y="-1100.6" font-family="Arial" font-size="14.00">working_memory </text>
|
|
227
|
+
<text text-anchor="start" x="1225.24" y="-1100.6" font-family="Arial" font-size="14.00" fill="#666666">[boolean]</text>
|
|
228
|
+
<text text-anchor="start" x="1282.85" y="-1100.6" font-family="Arial" font-size="14.00"> True if this node is currently in the robot working memory</text>
|
|
207
229
|
</g>
|
|
208
|
-
<!-- public.
|
|
230
|
+
<!-- public.robot_nodes->public.nodes -->
|
|
209
231
|
<g id="edge5" class="edge">
|
|
210
|
-
<title>public.
|
|
211
|
-
<path fill="none" stroke="black" d="
|
|
212
|
-
<polygon fill="black" stroke="black" points="
|
|
213
|
-
<text text-anchor="start" x="
|
|
232
|
+
<title>public.robot_nodes:node_id->public.nodes:id</title>
|
|
233
|
+
<path fill="none" stroke="black" d="M1096.53,-1226.28C1028.54,-1216.21 1056.39,-1102.78 1107.77,-1045.2 1197.41,-944.75 1319.03,-1109.77 1408.53,-1009.2 1460.39,-950.93 1487.53,-658.2 1409.53,-658.2"/>
|
|
234
|
+
<polygon fill="black" stroke="black" points="1096.46,-1226.28 1106.12,-1231.47 1101.78,-1226.65 1106.1,-1226.95 1106.1,-1226.95 1106.1,-1226.95 1101.78,-1226.65 1106.75,-1222.49 1096.46,-1226.28"/>
|
|
235
|
+
<text text-anchor="start" x="848.61" y="-1211" font-family="Arial" font-size="10.00">FOREIGN KEY (node_id) REFERENCES nodes(id) ON DELETE CASCADE</text>
|
|
214
236
|
</g>
|
|
215
|
-
<!-- public.
|
|
216
|
-
<g id="
|
|
217
|
-
<title>public.
|
|
218
|
-
<
|
|
219
|
-
<polygon fill="
|
|
220
|
-
<text text-anchor="start" x="
|
|
237
|
+
<!-- public.robots -->
|
|
238
|
+
<g id="node5" class="node">
|
|
239
|
+
<title>public.robots</title>
|
|
240
|
+
<polygon fill="#efefef" stroke="none" points="1513.41,-766 1513.41,-812 2017.62,-812 2017.62,-766 1513.41,-766"/>
|
|
241
|
+
<polygon fill="none" stroke="black" points="1513.41,-766 1513.41,-812 2017.62,-812 2017.62,-766 1513.41,-766"/>
|
|
242
|
+
<text text-anchor="start" x="1656.02" y="-789.8" font-family="Arial Bold" font-size="18.00">public.robots</text>
|
|
243
|
+
<text text-anchor="start" x="1750.51" y="-789.8" font-family="Arial" font-size="14.00"> </text>
|
|
244
|
+
<text text-anchor="start" x="1781.63" y="-789.8" font-family="Arial" font-size="14.00" fill="#666666">[BASE TABLE]</text>
|
|
245
|
+
<text text-anchor="start" x="1614.57" y="-775.4" font-family="Arial" font-size="14.00" fill="#333333">Registry of all LLM robots using the HTM system</text>
|
|
246
|
+
<polygon fill="none" stroke="black" points="1513.41,-735.2 1513.41,-766 2017.62,-766 2017.62,-735.2 1513.41,-735.2"/>
|
|
247
|
+
<text text-anchor="start" x="1520.41" y="-747.4" font-family="Arial" font-size="14.00">created_at </text>
|
|
248
|
+
<text text-anchor="start" x="1590.45" y="-747.4" font-family="Arial" font-size="14.00" fill="#666666">[timestamp with time zone]</text>
|
|
249
|
+
<text text-anchor="start" x="1756.18" y="-747.4" font-family="Arial" font-size="14.00"> When the robot was first registered</text>
|
|
250
|
+
<polygon fill="none" stroke="black" points="1513.41,-704.4 1513.41,-735.2 2017.62,-735.2 2017.62,-704.4 1513.41,-704.4"/>
|
|
251
|
+
<text text-anchor="start" x="1520.41" y="-716.6" font-family="Arial" font-size="14.00">id </text>
|
|
252
|
+
<text text-anchor="start" x="1535.19" y="-716.6" font-family="Arial" font-size="14.00" fill="#666666">[bigint]</text>
|
|
253
|
+
<polygon fill="none" stroke="black" points="1513.41,-673.6 1513.41,-704.4 2017.62,-704.4 2017.62,-673.6 1513.41,-673.6"/>
|
|
254
|
+
<text text-anchor="start" x="1520.41" y="-685.8" font-family="Arial" font-size="14.00">last_active </text>
|
|
255
|
+
<text text-anchor="start" x="1590.44" y="-685.8" font-family="Arial" font-size="14.00" fill="#666666">[timestamp with time zone]</text>
|
|
256
|
+
<text text-anchor="start" x="1756.16" y="-685.8" font-family="Arial" font-size="14.00"> Last time the robot accessed the system</text>
|
|
257
|
+
<polygon fill="none" stroke="black" points="1513.41,-642.8 1513.41,-673.6 2017.62,-673.6 2017.62,-642.8 1513.41,-642.8"/>
|
|
258
|
+
<text text-anchor="start" x="1520.41" y="-655" font-family="Arial" font-size="14.00">name </text>
|
|
259
|
+
<text text-anchor="start" x="1559.32" y="-655" font-family="Arial" font-size="14.00" fill="#666666">[text]</text>
|
|
260
|
+
<text text-anchor="start" x="1589.66" y="-655" font-family="Arial" font-size="14.00"> Human-readable name for the robot</text>
|
|
261
|
+
</g>
|
|
262
|
+
<!-- public.robot_nodes->public.robots -->
|
|
263
|
+
<g id="edge4" class="edge">
|
|
264
|
+
<title>public.robot_nodes:robot_id->public.robots:id</title>
|
|
265
|
+
<path fill="none" stroke="black" d="M1748.29,-1164.37C1787.26,-1155.42 1758.31,-1090.19 1737.26,-1045.2 1681.95,-927.01 1568.66,-973.42 1513.41,-855.2 1487.93,-800.68 1452.23,-719.8 1512.41,-719.8"/>
|
|
266
|
+
<polygon fill="black" stroke="black" points="1748.54,-1164.34 1738.13,-1160.89 1743.23,-1164.89 1738.92,-1165.33 1738.92,-1165.33 1738.92,-1165.33 1743.23,-1164.89 1739.05,-1169.84 1748.54,-1164.34"/>
|
|
267
|
+
<text text-anchor="start" x="1745.26" y="-1149.4" font-family="Arial" font-size="10.00">FOREIGN KEY (robot_id) REFERENCES robots(id) ON DELETE CASCADE</text>
|
|
268
|
+
</g>
|
|
269
|
+
<!-- public.schema_migrations -->
|
|
270
|
+
<g id="node6" class="node">
|
|
271
|
+
<title>public.schema_migrations</title>
|
|
272
|
+
<polygon fill="#efefef" stroke="none" points="1841.54,-1247.6 1841.54,-1283.2 2169.49,-1283.2 2169.49,-1247.6 1841.54,-1247.6"/>
|
|
273
|
+
<polygon fill="none" stroke="black" points="1841.54,-1247.6 1841.54,-1283.2 2169.49,-1283.2 2169.49,-1247.6 1841.54,-1247.6"/>
|
|
274
|
+
<text text-anchor="start" x="1848.54" y="-1261" font-family="Arial Bold" font-size="18.00">public.schema_migrations</text>
|
|
275
|
+
<text text-anchor="start" x="2038" y="-1261" font-family="Arial" font-size="14.00"> </text>
|
|
276
|
+
<text text-anchor="start" x="2069.11" y="-1261" font-family="Arial" font-size="14.00" fill="#666666">[BASE TABLE]</text>
|
|
277
|
+
<polygon fill="none" stroke="black" points="1841.54,-1216.8 1841.54,-1247.6 2169.49,-1247.6 2169.49,-1216.8 1841.54,-1216.8"/>
|
|
278
|
+
<text text-anchor="start" x="1848.54" y="-1229" font-family="Arial" font-size="14.00">version </text>
|
|
279
|
+
<text text-anchor="start" x="1897.56" y="-1229" font-family="Arial" font-size="14.00" fill="#666666">[varchar]</text>
|
|
221
280
|
</g>
|
|
222
281
|
</g>
|
|
223
282
|
</svg>
|