Phase 3 of 13
4.1 Monorepo Task Runner —
Phase 3: Tech Stack
Tech Stack complete — 4 languages, 4 build systems, 4 test frameworks, unified codegen pipeline.
1. Languages & Versions
TypeScript
ES2022
Target, strict mode
Python
>=3.11
Classifiers through 3.14
Go
1.24
Standard toolchain
C# 14
.NET 8
SDK 10, LangVersion 14
| Language | Version Constraint | Evidence |
|---|---|---|
| TypeScript | ES2022 target, strict mode | nodejs/tsconfig.json:3-4 — "target": "ES2022", "module": "ES2022" |
| Node.js | >=20.0.0 (CI uses Node 22) |
nodejs/package.json:69 — "node": ">=20.0.0" |
| Python | >=3.11 (classifiers through 3.14) |
python/pyproject.toml:10 — requires-python = ">=3.11" |
| Go | 1.24 | go/go.mod:3 — go 1.24 |
| C# | Language version 14 (.NET 8 TFM, .NET SDK 10) | dotnet/Directory.Build.props:4-5 — <TargetFramework>net8.0</TargetFramework> / <LangVersion>14</LangVersion> |
Language Distribution
TypeScript
Primary SDK + Codegen scripts
Python
SDK + Async support
Go
SDK + Stdlib approach
C#
SDK + AOT compatible
2. Runtime Dependencies (per SDK)
2.1 Node.js SDK
Source: nodejs/package.json:46-49
| Package | Version | Purpose |
|---|---|---|
@github/copilot |
^1.0.3-0 |
GitHub Copilot CLI binary — the process the SDK drives over JSON-RPC |
vscode-jsonrpc |
^8.2.1 |
JSON-RPC 2.0 protocol implementation for bidirectional stdio communication |
zod |
^4.3.6 |
Runtime schema validation and type-safe parsing of JSON-RPC messages |
2.2 Python SDK
Source: python/pyproject.toml:25-28
| Package | Version | Purpose |
|---|---|---|
python-dateutil |
>=2.9.0.post0 |
Date/time parsing for protocol timestamps |
pydantic |
>=2.0 |
Data validation and settings management via dataclass-style models |
2.3 Go SDK
Source: go/go.mod:5-10
| Package | Version | Purpose |
|---|---|---|
github.com/google/jsonschema-go |
v0.4.2 |
JSON Schema generation from Go types (for tool parameter schemas) |
github.com/klauspost/compress |
v1.18.3 |
High-performance compression |
github.com/google/uuid |
v1.6.0 |
UUID generation for request IDs and correlation tokens |
2.4 .NET SDK
Source: dotnet/src/GitHub.Copilot.SDK.csproj:33-38, dotnet/Directory.Packages.props:8-14
| Package | Version | Purpose |
|---|---|---|
Microsoft.Extensions.AI.Abstractions |
10.2.0 |
AI model abstractions (IChatClient, etc.) |
Microsoft.Extensions.Logging.Abstractions |
10.0.2 |
Logging abstractions |
StreamJsonRpc |
2.24.84 |
Microsoft's JSON-RPC 2.0 over streams (stdio) |
System.Text.Json |
10.0.2 |
High-performance JSON serialization |
Microsoft.SourceLink.GitHub |
10.0.102 |
Source file links in PDB symbols |
3. Dev Dependencies (per SDK)
3.1 Node.js SDK
Source: nodejs/package.json:51-67
| Package | Version | Purpose |
|---|---|---|
esbuild |
^0.27.2 |
Ultra-fast JS/TS bundler |
eslint |
^9.0.0 |
Linting |
@typescript-eslint/* |
^8.54.0 |
TypeScript ESLint rules/parser |
prettier |
^3.8.1 |
Code formatter |
vitest |
^4.0.18 |
Test framework |
typescript |
^5.0.0 |
Compiler |
tsx |
^4.20.6 |
TypeScript execution engine |
json-schema-to-typescript |
^15.0.4 |
Codegen: JSON Schema → TS interfaces |
quicktype-core |
^23.2.6 |
Multi-language type generation |
rimraf |
^6.1.2 |
Cross-platform rm -rf |
semver |
^7.7.3 |
Version management |
3.2 Python SDK
Source: python/pyproject.toml:34-42
| Package | Version | Purpose |
|---|---|---|
ruff |
>=0.1.0 |
Fast linter + formatter |
ty |
>=0.0.2 |
Type checking |
pytest |
>=7.0.0 |
Test framework |
pytest-asyncio |
>=0.21.0 |
Async test support |
pytest-timeout |
>=2.0.0 |
Test timeouts |
httpx |
>=0.24.0 |
Async HTTP client (test infra) |
3.3 .NET SDK (Test Project)
Source: dotnet/test/GitHub.Copilot.SDK.Test.csproj:17-29
| Package | Version | Purpose |
|---|---|---|
xunit |
2.9.3 |
Test framework |
xunit.runner.visualstudio |
3.1.5 |
Test runner adapter |
Microsoft.NET.Test.Sdk |
18.3.0 |
Test SDK |
coverlet.collector |
6.0.4 |
Code coverage |
4. Build Tools & Systems
4.1 Monorepo Task Runner — just
Source: justfile:1-230
just is the top-level task runner with unified recipes:
| Recipe | Actions |
|---|---|
just format |
gofmt, ruff format, prettier, dotnet format |
just lint |
golangci-lint, ruff check + ty check, eslint + tsc --noEmit, dotnet format --verify-no-changes |
just test |
go test, pytest, vitest, dotnet test |
just install |
npm ci, uv pip install, go mod download, dotnet restore |
just scenario-build |
Compiles all cross-language scenario samples |
just validate-docs |
Extracts and validates documentation code examples |
4.2 Node.js Build: esbuild + tsc
Source: nodejs/esbuild-copilotsdk-nodejs.ts:1-19
- esbuild bundles
src/**/*.ts→ ESM JavaScript (ES2022, Node.js) - tsc generates
.d.tsdeclaration files only (emitDeclarationOnly: true)
4.3 .NET Build: MSBuild/dotnet CLI
- .NET SDK
10.0.100with"rollForward": "major"(dotnet/global.json:3-4) - Target:
net8.0, AOT-compatible (<IsAotCompatible>true</IsAotCompatible>) - Central package management enabled
- Custom MSBuild target extracts Copilot CLI version from nodejs/package-lock.json
4.4 Python Build: setuptools + wheel
setuptools >=45+wheel+setuptools_scm >=6.2(python/pyproject.toml:2)- Platform wheels built by scripts/build-wheels.mjs
4.5 Go Build: standard toolchain
go build,go mod(Go 1.24)
5. Code Generation Pipeline
Source: scripts/codegen/package.json:1-18
Generates typed protocol bindings for all four SDKs from shared JSON Schema.
| Tool | Purpose |
|---|---|
json-schema-to-typescript |
JSON Schema → TypeScript interfaces |
quicktype-core |
Multi-language type generation (C#, Python, Go) |
Scripts execution order:
tsx typescript.ts && tsx csharp.ts && tsx python.ts && tsx go.ts
Generated Output Locations
| SDK | Output Path | Files |
|---|---|---|
| Node.js | nodejs/src/generated/ |
rpc.ts, session-events.ts |
| Python | python/copilot/generated/ |
rpc.py, session_events.py |
| Go | go/generated_*.go and go/rpc/ |
generated_*.go, rpc/* |
| .NET | dotnet/src/Generated/ |
Rpc.cs, SessionEvents.cs |
CI verification: codegen-check.yml re-runs codegen and checks
git status --porcelain to ensure generated files are always up-to-date.
6. CI/CD Workflows
| Workflow | Purpose | Trigger |
|---|---|---|
nodejs-sdk-tests.yml |
Lint + typecheck + test Node.js SDK (Linux/macOS/Windows) | push, PR, merge_group |
python-sdk-tests.yml |
Lint + type check + test Python SDK (3 OSes) | push, PR, merge_group |
go-sdk-tests.yml |
fmt + golangci-lint + test Go SDK (3 OSes) | push, PR, merge_group |
dotnet-sdk-tests.yml |
format + build + test .NET SDK (3 OSes) | push, PR, merge_group |
codegen-check.yml |
Verify generated files up-to-date | push, PR |
scenario-builds.yml |
Compile-check all scenario samples | push, PR, merge_group |
publish.yml |
Multi-SDK publish (npm, NuGet, PyPI) + GitHub Release | manual |
docs-validation.yml |
Validate docs code examples | PR |
7. Linting & Formatting
| SDK | Linter | Formatter | Config |
|---|---|---|---|
| Node.js | ESLint 9 (flat config) | Prettier 3.x | nodejs/eslint.config.js, .prettierrc.json |
| Python | Ruff (E/W/F/I/UP rules) | Ruff formatter | python/pyproject.toml:50-69 |
| Go | golangci-lint (govet, ineffassign, staticcheck) | gofmt | go/.golangci.yml |
| .NET | dotnet format (AnalysisLevel 10.0-minimum) | dotnet format | dotnet/Directory.Build.props:8 |
8. Testing Frameworks
| SDK | Framework | Config | Key Settings |
|---|---|---|---|
| Node.js | Vitest 4.x | nodejs/vitest.config.ts | 30s timeout, forks pool, globals |
| Python | pytest 7+ | python/pyproject.toml:81-86 | async mode auto, pytest-timeout |
| Go | go test (stdlib) |
go/test.sh | -race flag enabled |
| .NET | xUnit 2.9 | dotnet/test/GitHub.Copilot.SDK.Test.csproj | coverlet for coverage |
9. Package Managers
| Ecosystem | Manager | Lock File |
|---|---|---|
| Node.js | npm | package-lock.json |
| Python | uv (Astral) | uv.lock |
| Go | Go Modules | go.sum |
| .NET | NuGet (central) | Directory.Packages.props |
10. Protocol & Communication
JSON-RPC 2.0 over stdio to the Copilot CLI process:
IPC Communication Architecture
flowchart LR
subgraph SDK["SDK Process"]
direction TB
Node["Node.js"]
Py["Python"]
Go["Go"]
Net[".NET"]
end
subgraph CLI["Copilot CLI Process"]
Binary["@github/copilot\nCLI binary\n(AI backend)"]
end
SDK -->|"stdin (JSON-RPC 2.0)"| CLI
CLI -->|"stdout (responses)"| SDK
CLI -->|"stderr (diagnostics)"| SDK
| SDK | JSON-RPC Implementation | Schema Validation |
|---|---|---|
| Node.js | vscode-jsonrpc ^8.2.1 |
zod ^4.3.6 |
| Python | Custom (pydantic-based) | pydantic >=2.0 |
| Go | Custom (stdlib encoding/json) |
jsonschema-go v0.4.2 |
| .NET | StreamJsonRpc 2.24.84 |
System.Text.Json 10.0.2 (AOT source-gen) |
Summary Matrix
Summary Matrix
flowchart LR
subgraph TS["<b>Node.js</b>"]
direction TB
TS1["Language: TypeScript #40;ES2022#41;<br/>Build: esbuild + tsc<br/>Test: Vitest 4.x<br/>Lint: ESLint 9 + Prettier 3<br/>JSON-RPC: vscode-jsonrpc<br/>Registry: npm<br/>Pkg Mgr: npm"]
end
subgraph PY["<b>Python</b>"]
direction TB
PY1["Language: Python 3.11+<br/>Build: setuptools<br/>Test: pytest 7+<br/>Lint: Ruff + ty<br/>JSON-RPC: custom / pydantic<br/>Registry: PyPI<br/>Pkg Mgr: uv"]
end
subgraph GO["<b>Go</b>"]
direction TB
GO1["Language: Go 1.24<br/>Build: go build<br/>Test: go test -race<br/>Lint: golangci-lint<br/>JSON-RPC: custom / stdlib<br/>Registry: Go modules<br/>Pkg Mgr: go mod"]
end
subgraph NET["<b>.NET</b>"]
direction TB
NET1["Language: C# 14 / .NET 8<br/>Build: MSBuild<br/>Test: xUnit 2.9<br/>Lint: dotnet format<br/>JSON-RPC: StreamJsonRpc<br/>Registry: NuGet<br/>Pkg Mgr: NuGet #40;central#41;"]
end