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
88 changes: 88 additions & 0 deletions .github/workflows/docs-pages.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
name: Docs

on:
push:
branches:
- main
paths:
- 'website/**'
- '.github/workflows/docs-pages.yml'
pull_request:
branches:
- main
paths:
- 'website/**'
- '.github/workflows/docs-pages.yml'
workflow_dispatch:

permissions:
contents: read

concurrency:
group: pages-${{ github.ref }}
cancel-in-progress: true

jobs:
build:
name: Build documentation
runs-on: ubuntu-latest
permissions:
contents: read
pages: read
defaults:
run:
working-directory: website
steps:
- name: Check out repository
uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 22
cache: npm
cache-dependency-path: website/package-lock.json

- name: Install dependencies
run: npm ci

- name: Check formatting
run: npm run format:check

- name: Lint and check language parity
run: npm run lint

- name: Configure GitHub Pages
if: github.event_name != 'pull_request' && github.ref == 'refs/heads/main'
uses: actions/configure-pages@v5

- name: Build website
run: npm run build
env:
DOCS_BASE: /Code/
DOCS_ORIGIN: https://a3s-lab.github.io

- name: Check built routes and assets
run: npm run check:site

- name: Upload GitHub Pages artifact
if: github.event_name != 'pull_request' && github.ref == 'refs/heads/main'
uses: actions/upload-pages-artifact@v4
with:
path: website/doc_build

deploy:
name: Deploy documentation
if: github.event_name != 'pull_request' && github.ref == 'refs/heads/main'
needs: build
runs-on: ubuntu-latest
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
14 changes: 14 additions & 0 deletions website/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Local
.DS_Store
*.local
*.log*

# Dist
node_modules
dist/
doc_build/

# IDE
.vscode/*
!.vscode/extensions.json
.idea
4 changes: 4 additions & 0 deletions website/.prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Lock files
package-lock.json
pnpm-lock.yaml
yarn.lock
3 changes: 3 additions & 0 deletions website/.prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"singleQuote": true
}
13 changes: 13 additions & 0 deletions website/AGENTS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
## Tools

### Prettier

- Run `npm run format` to format your code

## Docs

- Rslint: https://rslint.rs/llms.txt

### Rslint

- Run `npm run lint` to lint your code
26 changes: 26 additions & 0 deletions website/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# A3S Code website

The official multilingual website and documentation for
[A3S Code](https://github.com/A3S-Lab/Code), built with Rspress.

## Local development

```bash
npm ci
npm run dev
```

The production site is served from `/Code/`. Override `DOCS_BASE` and
`DOCS_ORIGIN` only when previewing another deployment target.

## Checks

```bash
npm run format:check
npm run lint
npm run build
```

The published documentation currently contains only the active `v6` line.
When a new major line ships, add a version snapshot under `docs/<version>` and
then list it in `multiVersion.versions` in `rspress.config.ts`.
16 changes: 16 additions & 0 deletions website/docs/public/a3s-code-mark.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 6 additions & 0 deletions website/docs/public/favicon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
68 changes: 68 additions & 0 deletions website/docs/public/social-card.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
12 changes: 12 additions & 0 deletions website/docs/v6/en/_meta.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
[
{
"type": "dir",
"name": "guide",
"label": "Documentation"
},
{
"type": "dir",
"name": "api",
"label": "API"
}
]
42 changes: 42 additions & 0 deletions website/docs/v6/en/_nav.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
[
{
"text": "Docs",
"link": "/guide/",
"activeMatch": "^/guide/"
},
{
"text": "Examples",
"link": "/guide/examples/",
"activeMatch": "^/guide/examples/"
},
{
"text": "API",
"link": "/api/",
"activeMatch": "^/api/"
},
{
"text": "Resources",
"items": [
{
"text": "GitHub",
"link": "https://github.com/A3S-Lab/Code"
},
{
"text": "Changelog",
"link": "https://github.com/A3S-Lab/Code/blob/main/CHANGELOG.md"
},
{
"text": "Rust API",
"link": "https://docs.rs/a3s-code-core"
},
{
"text": "npm",
"link": "https://www.npmjs.com/package/@a3s-lab/code"
},
{
"text": "PyPI",
"link": "https://pypi.org/project/a3s-code/"
}
]
}
]
44 changes: 44 additions & 0 deletions website/docs/v6/en/api/index.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
---
title: APIs and packages
description: Entry points for the A3S Code Rust, Node.js, and Python APIs and their shared runtime contract.
---

# APIs and packages

The four A3S Code product surfaces share one runtime kernel while serving
different integration needs. Treat each registry and
[GitHub Releases](https://github.com/A3S-Lab/Code/releases) as the source of
truth for package versions and release status.

| Surface | Package or command | API entry | Use it for |
| -------- | ------------------ | -------------------------------------------------- | --------------------------------------------- |
| Terminal | `a3s code` | [A3S CLI](https://github.com/A3S-Lab/CLI) | Run the interactive coding product |
| Rust | `a3s-code-core` | [docs.rs](https://docs.rs/a3s-code-core) | Complete runtime API and extension traits |
| Node.js | `@a3s-lab/code` | [npm](https://www.npmjs.com/package/@a3s-lab/code) | Native N-API bindings and async event streams |
| Python | `a3s-code` | [PyPI](https://pypi.org/project/a3s-code/) | Synchronous and asynchronous PyO3 APIs |

## Install

```bash
# Rust
cargo add a3s-code-core

# Node.js
npm install @a3s-lab/code

# Python
python -m pip install a3s-code
```

## Cross-language contract

Versioned events, durable snapshots, and explicit lifecycle methods form the
cross-language product boundary. Start with the
[API contract](/guide/api-contract), then continue to
[sessions](/guide/sessions), [tools](/guide/tools),
[workspace backends](/guide/workspace-backends), and
[persistence](/guide/persistence).

Replaceable host extension boundaries include `LlmClient`, `ContextProvider`,
`MemoryStore`, `SessionStore`, workspace services, tools, permissions,
confirmations, hooks, security providers, MCP transports, and graph stores.
Loading
Loading