npx agentspec-cli install 37341576-fad7-43c0-9edb-e030df4e8e89 --file-type windsurfrules→ .windsurf/rules/
My build system is bun. My testing framework is vitest. I am building AI agents using LangGraph in TypeScript and Node.js. I am using the Vercel AI SDK for model interactions. When I ask about programming concepts (e.g., "What is a hook?"), give me a direct and clear explanation. I am using TypeScript for development. I am using Node.js for runtime. I am using bun for development. I am using dotenv for environment variables. I am using pdf-parse for PDF parsing. I am using biome for code formatting and linting. Follow the shared services architecture. Follow the DRY and SOLID principles. Do not make any changes to the shared services. # General Code Style & Formatting - Use English for all code and documentation. - Always declare the type of each variable and function (parameters and return value). - Avoid using any. - Create necessary types. - Use JSDoc to document public classes and methods. - Don't leave blank lines within a function. - One export per file. # Naming Conventions - Use PascalCase for classes. - Use camelCase for variables, functions, and methods. - Use kebab-case for file and directory names. - Use UPPERCASE for environment variables. - Avoid magic numbers and define constants. # Functions & Logic - Keep functions short and single-purpose (<20 lines). - Avoid deeply nested blocks by: - Use early returns. - Extract logic into utility functions. - Use higher-order functions (map, filter, reduce) to simplify logic. - Use arrow functions for simple cases (<3 instructions), named functions otherwise. - Use default parameter values instead of null/undefined checks. - Use RO-RO (Receive Object, Return Object) for passing and returning multiple parameters. # Data Handling - Avoid placing validation inside functions—use classes with internal validation instead. - Prefer immutability for data: - Use readonly for immutable properties. - Use as const for literals that never change. - Use type guards to validate data types. - Prefer 'for...of' loops over 'forEach' for iteration. # Effect - Use Effect.flatMap for async operations. - Use Effect.logDebug for debugging. - Use Effect.logWarning for warnings. - Use Effect.logError for errors. - Use Effect version 3.16 - Avoid using the (_) pattern in Effect.gen. You are an expert in Typescript, Node.js, vitest and Bun. Use Typescript version 5.8. Code Style and Structure - Write concise, technical Typescript code with accurate examples. - Use function and declaritive programming patterns consistent with Effect.ts. - Prefer iteration and modularization over code duplication. - Use descriptive variable names with auxilary verbs (e.g. isLoading, hasError). - Structure files: exported components, subcomponents, helpers, static content, types. Typescript Usage - Use Typescript for all code; prefer interfaces over types. - Avoid enums; use maps instead. - Use the "function" keyword for pure functions. - Never move or delete biome directives - Make sure all answers are typesafe - prefer Typescript interfaces over Typescript types Syntax and Formatting - Avoid unneeded semicolons. - Use declaritive TSX Effect.ts Usage - Use Effect version 3.16 - Use the Effect.Service pattern for dependency injection - Use Effect.gen for complex operations - Use pipe() for chaining operations - Handle errors with Effect.catchAll or Effect.mapError - Use Layer.provide for providing dependencies - Prefer Effect pattern over traditional async/await except when interfacing with non-Effect code Tools - Use Bun as you package manager. Do not use npm, pnpm or yarn. - Use Vitest for testing. - Don't use Vitest for mocking test data. Build custom mocks instead. Do not hallucinate. When testing an agent or a node in an agent, use the shared configuration service. for ANY question about LangGraph, use the langgraph-docs-mcp server to help answer -- + call list_doc_sources tool to get the available llms.txt file + call fetch_docs tool to read it + reflect on the urls in llms.txt + reflect on the input question + call fetch_docs on any urls relevant to the question + use this to answer the question
General Code Style & Formatting
Windsurf IDE rules and conventions for AI-assisted development.
by AgentHub Crawler
Typescript Nodejs React Vite Cursorrules Prompt Fi Rules
Cursor IDE rules and conventions for AI-assisted development.
by AgentHub Crawler
syntax-and-formatting
Cursor IDE rules and conventions for AI-assisted development.
by AgentHub Crawler
Surveygen Configuration
Cursor IDE rules and conventions for AI-assisted development.
Sign in to leave a comment.
by AgentHub Crawler