Kittyverse#111
Open
SNAPKITTYWEST wants to merge 6 commits into
Open
Conversation
NPC Engine (snapkitty-core/src/npc/): - memory.rs — WORM-backed NpcMemoryChain: every life event sealed, SHA-256 linked, tamper-proof. Relationships derived from history, not stored tags. EmotionalState computed from recent events. verify_chain() detects any edit. - character.rs — Para character: Big Five PersonalityMatrix, NeedVector with autonomy axis, ParaFsmState, SkillSet (coding skill included), procedural AppearanceDescriptor. drive_fsm() lets Para choose its own next action. - world.rs — SimWorld: lots, districts, WorldEvent sealing, season cycle. sovereign_city() pre-built starter town with 9 lot types. - mod.rs — Simulation orchestrator, introduce() seals FirstMeeting in both chains, paradigm_comparison() documents Traditional vs Sovereign in data. Markets (snapkitty-core/src/markets/): - finance.rs — SBIR/STTR grants, IpAsset registry, MilestoneRecord ($3M target) - kernel.rs — AgentBootRecord, FsmTransitionRecord, ConstitutionalAnchor, SafetyEnforcementRecord, mesh_boot_roster() for all 13 agent pairs - engine.rs — ChaosEvent, AgentIntercept, ArenaEvent, MeshHealthSnapshot TypeScript layer: - lib/markets/index.ts — routeToVertical(), VERTICALS registry, decisionToMarketEvent() - lib/agents/bodies/index.ts — LEDGER wired into getMesh() as pair 14 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
NPC Dialogue (snapkitty-core/src/npc/dialogue.rs): - build_context() — reads WORM chain, extracts relationship history, betrayal flags, shared secrets, emotional state into DialogueContext - build_nova_prompt() — generates LLM system prompt from memory chain context. Betrayal injects guard clause. Shared secrets inject vulnerability clause. NPC cannot pretend its history didn't happen — memory is architectural. - classify_tone() — maps emotional state + betrayal to DialogueTone enum - seal_exchange() — every conversation sealed to WORM chain C ABI / FFI (snapkitty-core/src/npc/ffi.rs): - Full C ABI over the NPC engine for Godot 4 GDExtension - snapkitty_spawn_para, snapkitty_seal_event, snapkitty_verify_memory - snapkitty_dialogue_prompt (returns JSON with NOVA prompt + tone + bond) - snapkitty_seal_dialogue (seals exchange + auto-records Conversation event) - snapkitty_relationship_bond/type, world tick, NPC count - Global state via once_cell Mutex — thread-safe, single world Godot 4 GDExtension (game-engine/): - gdextension/src/snapkitty_npc.h — C header for all FFI exports - gdextension/src/snapkitty_npc.cpp — GDExtension C++, registers SnapKittyNPC + SnapKittyWorld as native Godot 4 classes - gdextension/CMakeLists.txt — links Rust cdylib + godot-cpp - gdextension/snapkitty_npc.gdextension — Godot manifest (win/mac/linux) - project.godot — Godot 4.3 project, Forward+ renderer, input map - scripts/para_controller.gd — GDScript wrapper: spawn, seal_event, say() fires Ollama HTTP request with NOVA prompt, seals response to WORM - scripts/world_controller.gd — World clock, Para spawning, starter town (Sara/Alex/Maya/James pre-loaded with existing history) - scripts/dialogue_ui.gd — Tone-colored dialogue panel, live WORM seal display, relationship + bond shown in real time Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…n loop
This is not a life sim anymore. This is civilization infrastructure.
Rust (snapkitty-core/src/npc/):
- object_dna.rs — Every game object carries a WORM ledger. A sword knows
every kill, every owner, every repair. FORGE can rewrite behavior rules
mid-execution when env conditions change. ObjectRegistry manages a shard's
full object inventory.
- world_shard.rs — Ephemeral process-level spaces: spawn at kernel level,
evolve independently, seal all state transitions to WORM. ShardManager
gc_idle_shards() tears down empty spaces and preserves their history.
Two shards spawned identically will diverge into different civilizations.
- forge_engine.rs — Autonomous environmental evolution. Parses plain-language
intent ("build a trading post that charges 2% tax") → classifies build type
→ constructs shard + object DNA + economic rules + Lua behavior script.
SettlementPressure drives autonomous FORGE decisions based on trade volume,
conflict index, population density. The world builds itself.
TypeScript (collectivekitty/lib/game/meta-world.ts):
- executeIntent() — The recursive loop: NOVA parses intent → FORGE constructs
→ shard spawns → LEDGER seals. One call. The civilization builds itself.
- forgeAutonomousTick() — FORGE reads settlement pressure, decides what the
district needs next, and builds it without player input.
- getCivLog() — Full civilization event history sealed to WORM.
- tearDownShard() — Shard removed from active world, history preserved.
Nova Parr's architecture confirmed and implemented:
NOVA = cognition layer
FORGE = generative world construction
World Shards = autonomous localized reality containers
Object DNA = persistent behavioral identity
LEDGER/VAULT = economic memory + value coordination
Strategic position: Persistent Autonomous Civilization Simulation Infrastructure.
Not a Sims clone. Not a Paralives clone. A different category.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…trees KITTYVERSE — Persistent Autonomous Civilization Simulation Lua 5.4 Runtime (npc/lua_runtime.rs): - LuaSandbox: executes FORGE-authored scripts with full sandboxing (io/os/require/debug removed at load time — no escape vectors) - Exposes to Lua: seal(), apply_tax(), shard context table, args table - Every seal() call from Lua generates a WORM-LUA- entry - lua_to_json() converts Lua return values to serde_json - mlua 0.10 with lua54 + vendored features added to Cargo.toml Governance Engine (npc/governance.rs): - ShardConstitution: draft → add articles → ratify (sealed, immutable after) - ArticleKind: Property, Taxation, Trade, Social, Defense, Environmental, AIGovernance - GovernanceModel: Autonomous, PlayerCouncil, Hybrid, MerchantRepublic, Militocracy, Technocracy - Proposal + voting: majority of 3+ votes passes/rejects - InstitutionalMemory: WORM-chained governance history per shard - DiplomaticRelation: Neutral/Allied/Trading/Hostile/AtWar/Sanctioned between shards - sovereign_constitution(): default Hybrid governance, ratified by ATLAS+LEDGER+NEXUS Behavior Trees (npc/behavior_tree.rs): - BtNode: Sequence, Selector, Invert, Repeat, Condition, Action, Succeed - Recursive tick() — standard behavior tree semantics - survival_tree(): hunger > exhaustion > loneliness > boredom > idle - social_tree(bond, has_betrayal): betrayed NPC deflects, warm NPC initiates - merchant_tree(tax_rate): sell → collect tax → seal_to_ledger → restock Agent Sims: SACM agents (NOVA, FORGE, LEDGER, VAULT, NEXUS) now operate inside the KittyVerse world as first-class citizens, not just backends. Every agent decision is a WORM-sealed event in the civilization. Strategic position: KITTYVERSE — not a life sim, not a metaverse. Persistent Autonomous Civilization Simulation Infrastructure. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…e saves
KittyVerse is now a separate product on its own branch.
SnapKitty OS = enterprise infrastructure.
KittyVerse = civilization game powered by that infrastructure.
kittyverse/Cargo.toml — standalone crate, FSL-1.1, depends on snapkitty-core
kittyverse/src/save_token.rs — Async Save Token System:
- WorldStateSnapshot: complete serializable civilization state (Paras,
Shards, CivLog, Economy, WORM chain head for continuity proof)
- SaveToken::mint() — BASE64(GZIP(JSON(snapshot))) + HMAC-SHA256 player seal
- SaveToken::verify() — player key must match — no server needed
- SaveToken::hydrate() — restores full world state from token
- spawn_autosave() — tokio async background task, fires every N seconds,
never blocks gameplay, compresses and seals in spawn_blocking thread
- TokenStore — in-memory store (swap for Azure Blob on server)
- Tampered tokens rejected: HMAC fails, hydrate() returns Err
kittyverse/src/lib.rs — KittyVerse crate root
Company/product identity separated from SnapKitty OS constants.
game-engine/scripts/save_manager.gd — GDScript save layer:
- Autosave every 5 minutes via Timer (background, non-blocking)
- save_now() — manual save, mints token, emits save_completed signal
- load_from_token() — paste token string, verify seal, hydrate world
- export_to_clipboard() — player can copy their save anywhere
- Player sovereign key generated locally on first play, never sent to server
- Signal-driven: save_completed, save_failed, load_completed, load_failed
The player owns their save. No server. No cloud. No subscription.
The civilization token IS the world. It travels with the player.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.