counterfact-runtime-architecture

Evolve Counterfact runtime internals while preserving module boundaries and hot reload semantics.

169|19|Updated Apr 8, 2022
One-click install
npx skills add https://github.com/counterfact/api-simulator --skill counterfact-runtime-architecture
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: counterfact-runtime-architecture
Source: https://github.com/counterfact/api-simulator/tree/main/.github/skills/counterfact-runtime-architecture
Command: npx skills add https://github.com/counterfact/api-simulator --skill counterfact-runtime-architecture

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Safely change runtime/server orchestration, module loading, and context/registry behavior without breaking existing deployments or hot-reload guarantees.

Core Features & Use Cases

  • Isolate changes to runtime orchestration and module-loader boundaries to prevent cross-cutting regressions.
  • Preserve hot-reload behavior so updates apply without restart and context survives reloads.
  • Validate changes against existing architecture with explicit interfaces and documented conventions, minimizing risk when evolving internal server components.

Quick Start

To begin safely evolving the runtime architecture, review src/app.ts, src/api-runner.ts, and src/server/**, then implement changes following the conventions and run lint/build/test locally.

Frequently Asked Questions about counterfact-runtime-architecture

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I modify server runtime internals without breaking hot reload behavior?

To modify server runtime internals safely, isolate changes to module-loader boundaries and orchestration logic in src/app.ts and src/server/**. This preserves hot reload semantics so updates apply without restart and context survives reloads.

What is hot reload module loading and how does it work in a TypeScript server?

Hot reload module loading in a TypeScript server applies code updates without restarting the process. It coordinates runtime orchestration through explicit interfaces and documented conventions to ensure context survives reloads without cross-cutting regressions.

How do I update runtime architecture while preventing module coupling?

Update runtime architecture by enforcing explicit interfaces and documented conventions across src/api-runner.ts and related utilities. Run lint, build, and runtime tests locally to validate changes and prevent coupling between server components.

Can I change the module loader in src/app.ts without losing server context?

Yes, you can change the module loader in src/app.ts without losing server context by following conventions that preserve hot-reload semantics. Context survives reloads when changes are isolated to runtime orchestration boundaries.

What's the best way to validate runtime server changes before deployment?

The best way to validate runtime server changes is running lint, build, and runtime tests locally after modifying src/app.ts, src/api-runner.ts, or src/server/**/*.ts. This minimizes risk when evolving internal server components.

Why do my hot reload updates fail after changing server orchestration code?

Hot reload updates fail after changing server orchestration code when changes introduce module coupling or violate boundary conventions. Isolate changes to runtime orchestration and module-loader boundaries to prevent cross-cutting regressions that break reload behavior.