Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 7 additions & 6 deletions HACKATHON.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
Rebuild note: supersedes, see [ADR-003](ADR-003-single-crate-rebuild.md).

Working doc for the [Global AI Hackathon Series with Qwen Cloud](https://qwencloud-hackathon.devpost.com/)
submission. **Deadline: Jul 9, 2026, 2:00pm PT.**
submission. **Deadline: Jul 20, 2026, 2:00pm PT.** (Extended from Jul 9 — see
the [deadline extension](https://qwencloud-hackathon.devpost.com/updates/45184-more-time-to-build-submission-deadline-extended-to-july-20).)

## The pitch

Expand All @@ -25,7 +26,7 @@ Track-1 requirement → texo mechanism:

## Submission requirements → status

- [x] Public repo (`github.com/heyoub/texo`)
- [x] Public repo (`github.com/freebatteryfactory/texo`)
- [x] Open-source license, detectable in About (LICENSE-MIT + LICENSE-APACHE, matches Cargo.toml)
- [ ] Uses Qwen models on Qwen Cloud (DashScope OpenAI-compatible mode — see gaps below)
- [x] The agent itself (Track 1 wants an *agent*, not a library — `texo serve`)
Expand Down Expand Up @@ -223,12 +224,12 @@ unless time allows.

## Deployment update (Jul 6 rebuild closeout)

The deployed service is now one binary: `/opt/texo/bin/texo serve`. The systemd
The deploy ships a single binary: `/opt/texo/bin/texo serve`. The systemd

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Describe all binaries shipped by the deploy

The current deployment does not ship a single binary: deploy/deploy.sh builds and copies texo, texo-bvisor-extractor, and bvisor-linux-launcher (lines 12–17 and 33–37). This statement therefore gives submission readers an inaccurate description of the deployment artifact set; describe texo as the single service entrypoint while acknowledging its two confinement companion binaries.

Useful? React with 👍 / 👎.

unit still uses the `texo-agent` service name for operational continuity, but
the workspace and env file move to `/opt/texo/`. The deploy script stops the
old service, preserves the durable journal workspace, migrates a live env file
when present, and ships only the `texo` binary.
Comment on lines +227 to 231

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Correct the deployment artifact description.

deploy/deploy.sh also copies texo-bvisor-extractor and bvisor-linux-launcher into /opt/texo/bin/, so “ships only the texo binary” is inaccurate. Clarify that texo is the service binary while the deployment includes these supporting executables.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@HACKATHON.md` around lines 227 - 231, Update the deployment artifact
description in HACKATHON.md to state that texo is the service binary while the
deployment also includes the supporting texo-bvisor-extractor and
bvisor-linux-launcher executables; remove the inaccurate “only the texo binary”
wording.


texo remains on batpak family 0.9.0 by choice for the submission closeout; see
ROADMAP.md for the 0.10 hostbat manifest remount, MemFs/SimFs test stores, and
SSE replay work.
texo now builds on batpak family 0.10.0; see ROADMAP.md for the remaining
substrate work (hostbat manifest remount, MemFs/SimFs test stores, and SSE
replay).
Comment on lines +233 to +235

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Remove the completed hostbat remount from remaining work

The hostbat manifest remount is no longer remaining work: src/host/module.rs:25-31 builds a HostModule, and src/host/mod.rs:245-247 mounts it into HostBuilder before deriving the hostbat fingerprints. The referenced ROADMAP.md item is stale, so repeating it here contradicts the current implementation and the updated blog statement that the interim fingerprint has served its purpose.

Useful? React with 👍 / 👎.

17 changes: 9 additions & 8 deletions hackathon/ALIBABA-CLOUD-USAGE.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ One-hop map of where this project calls Alibaba Cloud, for submission review.

## 1. Qwen models via Model Studio (DashScope OpenAI-compatible mode)

Every model call in the running agent goes through one HTTP client
Every model call goes through one HTTP client
([`src/surfaces/openai.rs`](../src/surfaces/openai.rs)) whose base URL and
models are configuration, resolved by the AI gateway
([`src/gateway.rs`](../src/gateway.rs)). The deployed agent points at
([`src/gateway.rs`](../src/gateway.rs)). The agent's gateway is configured for
DashScope compatible mode:

```
Expand All @@ -18,7 +18,7 @@ TEXO_LLM_RELATE_MODEL=qwen3.7-max # semantic judge (POST /chat/completio
TEXO_LLM_EMBED_MODEL=text-embedding-v4 # candidate embed (POST /embeddings)
```

See [`deploy/env.example`](../deploy/env.example) for the full deployed
See [`deploy/env.example`](../deploy/env.example) for the full deploy
configuration (key redacted).

## 2. ECS / VPC provisioning (Alibaba Cloud OpenAPI via `aliyun` CLI)
Expand All @@ -37,9 +37,10 @@ backend host using these ECS/VPC API operations:
the instance; [`deploy/texo-agent.service`](../deploy/texo-agent.service)
runs it under systemd.

## 3. Live evidence
## 3. Deployment proof

[`scripts/proof-ecs.sh`](../scripts/proof-ecs.sh) is the recorded proof
pass: `/api/health` on the ECS host, a three-session memory arc (teach →
supersede → fresh-session recall with receipts), and the redacted host
environment showing the DashScope endpoint and Qwen model configuration.
[`scripts/proof-ecs.sh`](../scripts/proof-ecs.sh) is the deployment-proof
pass to run once the instance is live: `/api/health` on the ECS host, a
three-session memory arc (teach → supersede → fresh-session recall with
receipts), and the redacted host environment showing the DashScope endpoint
and Qwen model configuration.
6 changes: 3 additions & 3 deletions hackathon/blog-post.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,17 +50,17 @@ It cites its source. It narrates its own history, unprompted. It doesn't just fa

Then I looked at the repository and got angry at it. Six crates. Three async transports. tokio, axum, reqwest, and an MCP SDK — sitting on top of a substrate whose whole point is that it ships its own sync operation kit, host composition, receipt verification, and event lanes. I was dogfooding BatPak's journal and hand-rolling everything else it already provided. Mid-hackathon, deadline in three days, I made the call: rebuild from the ground up, all or nothing.

What made that sane instead of suicidal is that texo's identity lives in the math, not the code: a claim ID is a pure function of source, line, and normalized text. So the rebuild had a falsifiable acceptance test — flatten six crates into one, replace every async transport with hand-rolled sync code (HTTP server, SSE, the HTTPS client that talks to DashScope, MCP over stdio), move every surface onto receipt-verified operations, and then check that every claim ID in the golden corpus comes out *identical*. It did. 492 locked dependencies became 222, and the rebuilt system provably remembers everything the old one did.
What made that sane instead of suicidal is that texo's identity lives in the math, not the code: a claim ID is a pure function of source, line, and normalized text. So the rebuild had a falsifiable acceptance test — flatten six crates into one, replace every async transport with hand-rolled sync code (HTTP server, SSE, the HTTPS client that talks to DashScope, MCP over stdio), move every surface onto receipt-verified operations, and then check that every claim ID in the golden corpus comes out *identical*. It did. 492 locked dependencies became 324, and the rebuilt system provably remembers everything the old one did.

Sessions got the best upgrade: they moved *into* the journal. Each turn appends to a hidden per-session lane the moment it lands — no in-memory transcript, no separate session store. The journal is the session. The test that made me grin: append two turns, drop the process cold, reopen — both turns are there. Try that with a chat history dict.

Dogfooding cut both ways, too. Mid-rebuild I hit a real gap in my own library — hostbat's 0.9.0 builder couldn't thread status sinks or capability grants — so I filed the issue, and it was fixed upstream the same day. The fix landed in an unpublished 0.10.0, and rather than bet the deadline on a fresh breaking window, the hackathon ships on 0.9.0 *by choice*: a hand-rolled interface fingerprint stands in for the one missing feature, TODO-marked and roadmapped. Finding, filing, and fixing a substrate gap because a downstream project leaned on it hard — that's what the lean was for.
Dogfooding cut both ways, too. Mid-rebuild I hit a real gap in my own library — hostbat's 0.9.0 builder couldn't thread status sinks or capability grants — so I filed the issue, and it was fixed upstream the same day. The fix shipped in 0.10.0, and texo now builds on the 0.10.0 family; the hand-rolled interface fingerprint that stood in for that one missing feature during the 0.9.0 window has served its purpose. Finding, filing, and fixing a substrate gap because a downstream project leaned on it hard — that's what the lean was for.

The one-file UI became LiteShip (my Astro-based framework — third dogfood of the week): a chat pane whose replies carry per-claim citation chips, a memory sidebar and journal timeline riding a live SSE stream of the journal's own events, and a receipts panel that cross-checks the binary's interface fingerprint between the stream handshake and the host endpoint. When a supersession lands you watch it happen — the timeline ticks, the old claim slides into the superseded list with an arrow to what killed it.

And the finale, `just drift`: the freshly built binary ingests the repository's *own* markdown — README, specs, the old architecture ADRs, deliberately left standing — and reports which of its claims still hold. The old architecture's claims come back **superseded**, with receipts, by the rebuild ADR that replaced them. texo calling out its own drift is the purity test I didn't know I was building toward: the tool's thesis — prose rots, claims supersede — demonstrated on the tool.

Everything runs on Qwen Cloud through DashScope's OpenAI-compatible mode: `qwen3.7-max` for extraction, the relation judge, and chat; `text-embedding-v4` for the cosine prefilter; the backend on an Alibaba Cloud ECS instance in Singapore, next to the model endpoint.
It's wired to run on Qwen Cloud through DashScope's OpenAI-compatible mode — Qwen models for extraction, the relation judge, and chat; `text-embedding-v4` for the cosine prefilter — with the backend targeting an Alibaba Cloud ECS instance in Singapore, next to the model endpoint. (Deployment is scripted and committed; provisioning is the last box to check.)

<!-- TODO: video link -->

Expand Down
6 changes: 3 additions & 3 deletions hackathon/devpost-description.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,12 @@ The whole thing is one Rust binary. Every surface — CLI, HTTP, MCP — dispatc

## Built on Qwen Cloud

All three LLM roles — claim extraction, the relation judge, and chat — run on `qwen3.7-max`; the cosine prefilter uses `text-embedding-v4`. Both are served through Qwen Cloud's DashScope OpenAI-compatible mode (`dashscope-intl`, Singapore). The agent backend is deployed on an Alibaba Cloud ECS instance in Singapore (`ap-southeast-1`), same region as the model endpoint; the deploy configuration is committed in the repo.
<!-- TODO: confirm ECS deployment details + repo path of deploy script before submitting -->
All three LLM roles — claim extraction, the relation judge, and chat — are wired to Qwen models on Qwen Cloud's DashScope OpenAI-compatible mode (`dashscope-intl`, Singapore); the cosine prefilter uses `text-embedding-v4`. The agent backend targets an Alibaba Cloud ECS instance in the same Singapore region (`ap-southeast-1`) as the model endpoint; the deployment is fully scripted and committed to the repo (`deploy/provision-ecs.sh`, `deploy/deploy.sh`), with provisioning pending.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Build the UI before calling deployment fully scripted

From a fresh checkout, the cited deployment script is not yet complete: ui/dist is ignored and untracked, while deploy/deploy.sh:40 attempts to copy it without running the UI build or documenting that prerequisite. In that environment the advertised deployment stops at scp, so either add the UI build to the script/documented workflow or avoid claiming that provisioning is the only remaining step.

Useful? React with 👍 / 👎.

<!-- TODO: switch to present tense ("runs on <model-id>", "is deployed on ECS ...") once the instance is provisioned and a live Qwen Cloud run is verified end-to-end -->

## Pre-existing project disclosure

The texo library (claim-chain journal, replay, CLI, MCP server) predates the submission window; the rules allow this when the project is significantly updated in-window, so here is exactly what was built during the window: **the agent itself** (`texo serve` — the chat loop, crash-safe session lanes, session-end memorization pipeline, memory-grounded prompting, and its real-store test suite); **a ground-up architecture rebuild** (six crates flattened to one crate and one binary; tokio/axum/reqwest/rmcp replaced by hand-rolled sync HTTP, SSE, and MCP on the substrate's own primitives — 492 locked dependencies down to 222 — with every claim ID proven identical across the rewrite, so the rebuilt system demonstrably remembers everything the old one did); the **BatPak 0.9.0 migration**, behavior-preserving with an empirical store-compatibility proof (a 0.8.2-written store replays byte-identically under 0.9.0); **char-offset + model provenance** on every recorded claim (span byte ranges, extractor model, prompt version); **cluster-first relate**, the O(n²)→O(n·cluster) fix live-validated at 5/5 on the regression corpus; the **live UI** (LiteShip: chat with per-claim citation chips, a memory sidebar and journal timeline fed by the journal's own event stream, a receipts panel that cross-checks the binary's interface fingerprint between the stream handshake and the host endpoint, and the drift view); and the licensing/documentation compliance sweep. The full dated changelog is in `HACKATHON.md`.
The texo library (claim-chain journal, replay, CLI, MCP server) predates the submission window; the rules allow this when the project is significantly updated in-window, so here is exactly what was built during the window: **the agent itself** (`texo serve` — the chat loop, crash-safe session lanes, session-end memorization pipeline, memory-grounded prompting, and its real-store test suite); **a ground-up architecture rebuild** (six crates flattened to one crate and one binary; tokio/axum/reqwest/rmcp replaced by hand-rolled sync HTTP, SSE, and MCP on the substrate's own primitives — 492 locked dependencies down to 324 — with every claim ID proven identical across the rewrite, so the rebuilt system demonstrably remembers everything the old one did); the **BatPak 0.9.0 migration**, behavior-preserving with an empirical store-compatibility proof (a 0.8.2-written store replays byte-identically under 0.9.0); **char-offset + model provenance** on every recorded claim (span byte ranges, extractor model, prompt version); **cluster-first relate**, the O(n²)→O(n·cluster) fix live-validated at 5/5 on the regression corpus; the **live UI** (LiteShip: chat with per-claim citation chips, a memory sidebar and journal timeline fed by the journal's own event stream, a receipts panel that cross-checks the binary's interface fingerprint between the stream handshake and the host endpoint, and the drift view); and the licensing/documentation compliance sweep. The full dated changelog is in `HACKATHON.md`.

## Track 1 requirement mapping

Expand Down
Loading