Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
57 commits
Select commit Hold shift + click to select a range
38da8d6
fix: remove duplicate code in ens.ts
accessor-io May 3, 2025
0969081
fix: resolve duplicate code and type errors in ens.ts
accessor-io May 3, 2025
29eac3e
refactor: split ens service into modular files
accessor-io May 3, 2025
ee5eb76
feat(chains): Update chain configurations and network handling
accessor-io May 3, 2025
ca349ab
feat(prompts): Enhance user interaction prompts
accessor-io May 3, 2025
08a1d58
feat(balance): Improve balance checking service
accessor-io May 3, 2025
e5c4f13
feat(blocks): Update block service functionality
accessor-io May 3, 2025
366ca4b
feat(clients): Enhance client management
accessor-io May 3, 2025
7e7d3ef
feat(contracts): Update contract interaction service
accessor-io May 3, 2025
c0b0ac6
feat(services): Update service exports and organization
accessor-io May 3, 2025
b2f8a59
feat(tokens): Enhance token service functionality
accessor-io May 3, 2025
7efd0c0
feat(transactions): Major update to transaction service
accessor-io May 3, 2025
e845319
feat(transfer): Major refactor of transfer service
accessor-io May 3, 2025
2e22ed4
feat(types): add MCP SDK type declarations for better type safety
accessor-io May 3, 2025
73df63f
chore(config): update TypeScript config to include type declarations …
accessor-io May 3, 2025
6983475
feat(chains): enhance type safety and error handling in chain definit…
accessor-io May 3, 2025
39626b2
feat(prompts): improve type safety and validation in EVM prompts
accessor-io May 3, 2025
23ed275
fix(ens): use ENS_REGISTRY_ADDRESS and correct result mapping in ENS …
accessor-io May 5, 2025
6eccc37
feat(ens): add getRecentRegistrations function to query recent ENS na…
accessor-io May 5, 2025
9146af7
feat(scripts): add script to display recent ENS registrations
accessor-io May 5, 2025
6d2c963
fix(ens): correct import path for clients.js
accessor-io May 5, 2025
47627a1
fix(scripts): explicitly use mainnet chain for ENS registrations
accessor-io May 5, 2025
1884b68
fix(scripts): use network name instead of chain object for ENS regist…
accessor-io May 5, 2025
b1560dd
refactor(ens): simplify client initialization to only use public clie…
accessor-io May 5, 2025
94508cb
feat(scripts): make registration count configurable via command-line …
accessor-io May 5, 2025
b157a3a
refactor(ens): reorganize folder structure, improve script error hand…
accessor-io May 5, 2025
9ff9358
chore: remove old script location after moving to ens/scripts
accessor-io May 5, 2025
163bcda
feat(ens): add script to display ENS address history
accessor-io May 5, 2025
eff355c
refactor(ens): reorganize ENS service into modular structure with ind…
accessor-io May 5, 2025
958ea6c
refactor(ens): consolidate all ENS files into scripts folder
accessor-io May 5, 2025
0cefa29
refactor(ens): rename core files for better semantic clarity
accessor-io May 5, 2025
e82563d
feat(ens): add comprehensive test script for all ENS functionality
accessor-io May 5, 2025
1d811ee
feat(ens): add individual test scripts for each ENS functionality
accessor-io May 5, 2025
10f71ce
refactor(ens): update test scripts to use publicClient only
accessor-io May 5, 2025
63c9408
fix(ens): update test scripts to match type definitions
accessor-io May 5, 2025
47a7dc0
feat(ens): add registration cost estimation script
accessor-io May 5, 2025
487d8ae
feat(ens): add full registration implementation with commitment and r…
accessor-io May 5, 2025
5e07c09
feat(ens): add resolver setup and ENS contract addresses
accessor-io May 5, 2025
2a10369
feat(ens): add script to query ENS names by address or name
accessor-io May 5, 2025
245d5d2
feat(ens): enhance query script with subgraph, multi-coin, and batch …
accessor-io May 5, 2025
ad306ea
docs(ens): update query script usage examples with correct paths
accessor-io May 5, 2025
4476b5b
chore: add graphql-request dependency for ENS subgraph queries
accessor-io May 5, 2025
def7429
fix(ens): correct chain object handling in query script
accessor-io May 5, 2025
b0ff4d5
fix(ens): correct client initialization and type issues in query script
accessor-io May 5, 2025
221a4bb
feat: add MCP configuration system with auto-recognition patterns
accessor-io May 5, 2025
9ce0ba3
feat: implement auto-recognition service for MCP server
accessor-io May 5, 2025
fdeaaa7
feat: add logging utility for MCP server
accessor-io May 5, 2025
655c6f1
feat: integrate auto-recognition into MCP server
accessor-io May 5, 2025
b4e6d51
feat: add Electron application with modern UI and IPC communication
accessor-io May 5, 2025
43e0354
fix: update Electron setup for Bun compatibility
accessor-io May 5, 2025
4e87f31
feat: add proper Electron Forge configuration with TypeScript support
accessor-io May 5, 2025
8306e93
refactor: reorganize project structure for better maintainability
accessor-io May 6, 2025
db36337
docs: add CONTRIBUTING.md and update configuration paths
accessor-io May 6, 2025
8535f83
refactor: move core configuration to config directory and update impo…
accessor-io May 6, 2025
190ee5e
chore: add TypeScript and linting configurations
accessor-io May 6, 2025
a5f05ed
fix: update ENS resolution import path
accessor-io May 6, 2025
3c7883e
fix: update ENS functions import path
accessor-io May 6, 2025
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
1 change: 1 addition & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@

1 change: 1 addition & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@

1,632 changes: 1,515 additions & 117 deletions bun.lock

Large diffs are not rendered by default.

127 changes: 127 additions & 0 deletions config/core/mcp-config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,127 @@
import { z } from 'zod';

// Define pattern type
interface Pattern {
type: 'cursor' | 'command';
pattern: string;
description: string;
}

// Define the configuration schema
export const MCPConfigSchema = z.object({
autoRecognition: z.object({
enabled: z.boolean().default(true),
patterns: z.array(z.object({
type: z.enum(['cursor', 'command']),
pattern: z.string(),
description: z.string()
})).default([
{
type: 'cursor' as const,
pattern: 'cursor|ide|editor|code|file|project|workspace',
description: 'Patterns related to Cursor IDE interactions'
},
{
type: 'command' as const,
pattern: 'run|execute|command|cli|terminal|shell|npm|bun|yarn',
description: 'Patterns related to command execution'
}
]),
confidenceThreshold: z.number().min(0).max(1).default(0.7)
}),
features: z.object({
cursorIntegration: z.boolean().default(true),
commandExecution: z.boolean().default(true),
fileOperations: z.boolean().default(true),
gitOperations: z.boolean().default(true)
}),
logging: z.object({
level: z.enum(['debug', 'info', 'warn', 'error']).default('info'),
autoRecognition: z.boolean().default(true)
})
});

// Default configuration
export const defaultMCPConfig: MCPConfig = {
autoRecognition: {
enabled: true,
patterns: [
{
type: 'cursor',
pattern: 'cursor|ide|editor|code|file|project|workspace',
description: 'Patterns related to Cursor IDE interactions'
},
{
type: 'command',
pattern: 'run|execute|command|cli|terminal|shell|npm|bun|yarn',
description: 'Patterns related to command execution'
}
],
confidenceThreshold: 0.7
},
features: {
cursorIntegration: true,
commandExecution: true,
fileOperations: true,
gitOperations: true
},
logging: {
level: 'info',
autoRecognition: true
}
};

// Configuration type
export type MCPConfig = z.infer<typeof MCPConfigSchema>;

// Configuration manager class
export class MCPConfigManager {
private static instance: MCPConfigManager;
private config: MCPConfig;

private constructor() {
this.config = defaultMCPConfig;
}

public static getInstance(): MCPConfigManager {
if (!MCPConfigManager.instance) {
MCPConfigManager.instance = new MCPConfigManager();
}
return MCPConfigManager.instance;
}

public getConfig(): MCPConfig {
return this.config;
}

public updateConfig(newConfig: Partial<MCPConfig>): void {
this.config = {
...this.config,
...newConfig
};
}

public shouldHandleCursorInteraction(text: string): boolean {
if (!this.config.autoRecognition.enabled) return false;

const cursorPatterns = this.config.autoRecognition.patterns
.filter((p: Pattern) => p.type === 'cursor')
.map((p: Pattern) => new RegExp(p.pattern, 'i'));

return cursorPatterns.some((pattern: RegExp) => pattern.test(text));
}

public shouldHandleCommand(text: string): boolean {
if (!this.config.autoRecognition.enabled) return false;

const commandPatterns = this.config.autoRecognition.patterns
.filter((p: Pattern) => p.type === 'command')
.map((p: Pattern) => new RegExp(p.pattern, 'i'));

return commandPatterns.some((pattern: RegExp) => pattern.test(text));
}

public getFeatureStatus(feature: keyof typeof defaultMCPConfig.features): boolean {
return this.config.features[feature];
}
}
15 changes: 13 additions & 2 deletions tsconfig.json → config/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,19 @@
"outDir": "dist",
"sourceMap": true,
"declaration": true,
"resolveJsonModule": true
"resolveJsonModule": true,
"typeRoots": ["./node_modules/@types", "./src/types"],
"baseUrl": ".",
"paths": {
"@/*": ["src/*"],
"@config/*": ["config/*"]
},
"allowJs": true,
"checkJs": true
},
"include": ["src/**/*"],
"include": [
"src/**/*",
"config/**/*"
],
"exclude": ["node_modules", "dist"]
}
3 changes: 3 additions & 0 deletions config/vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"wake.compiler.solc.remappings": []
}
25 changes: 25 additions & 0 deletions config/webpack/webpack.main.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
import type { Configuration } from 'webpack';
import path from 'path';

export const mainConfig: Configuration = {
entry: './src/electron/index.ts',
target: 'electron-main',
module: {
rules: [
{
test: /\.ts$/,
exclude: /node_modules/,
use: {
loader: 'ts-loader',
},
},
],
},
resolve: {
extensions: ['.ts', '.js'],
},
output: {
path: path.resolve(__dirname, 'build/electron'),
filename: 'main.js',
},
};
29 changes: 29 additions & 0 deletions config/webpack/webpack.renderer.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
import type { Configuration } from 'webpack';
import path from 'path';

export const rendererConfig: Configuration = {
entry: './src/renderer/renderer.ts',
target: 'electron-renderer',
module: {
rules: [
{
test: /\.ts$/,
exclude: /node_modules/,
use: {
loader: 'ts-loader',
},
},
{
test: /\.css$/,
use: ['style-loader', 'css-loader'],
},
],
},
resolve: {
extensions: ['.ts', '.js', '.css'],
},
output: {
path: path.resolve(__dirname, 'build/renderer'),
filename: 'renderer.js',
},
};
13 changes: 13 additions & 0 deletions config/webpack/webpack.rules.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
export const rules = [
{
test: /\.ts$/,
exclude: /node_modules/,
use: {
loader: 'ts-loader',
},
},
{
test: /\.css$/,
use: ['style-loader', 'css-loader'],
},
];
1 change: 0 additions & 1 deletion CHANGELOG.md → docs/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,4 +33,3 @@
* npm public release ([df6d52d](https://github.com/mcpdotdirect/evm-mcp-server/commit/df6d52db01e0b290f0da7ea1a087243484ce4e5c))



93 changes: 93 additions & 0 deletions docs/CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
# Contributing to EVM MCP Server

Thank you for your interest in contributing to the EVM MCP Server project! This document provides guidelines and instructions for contributing to the project.

## Project Structure

```
evm-mcp-server/
├── config/ # Configuration files
│ ├── webpack/ # Webpack configurations
│ ├── vscode/ # VSCode settings
│ └── github/ # GitHub workflows
├── docs/ # Documentation
├── src/ # Source code
│ ├── main/ # Electron main process
│ ├── renderer/ # Frontend application
│ ├── core/ # Core Bitcoin functionality
│ ├── server/ # Backend server
│ ├── types/ # TypeScript type definitions
│ ├── utils/ # Shared utilities
│ └── constants/ # Application constants
└── scripts/ # Build and development scripts
```

## Development Setup

1. **Prerequisites**
- Node.js (v18 or later)
- pnpm or bun package manager
- Git

2. **Installation**
```bash
git clone https://github.com/your-org/evm-mcp-server.git
cd evm-mcp-server
pnpm install # or bun install
```

3. **Development**
```bash
pnpm electron:start # Start development server
```

## Code Style

- Follow TypeScript best practices
- Use ESLint and Prettier for code formatting
- Write meaningful commit messages
- Include tests for new features

## Pull Request Process

1. Fork the repository
2. Create a feature branch (`git checkout -b feature/amazing-feature`)
3. Commit your changes (`git commit -m 'feat: add amazing feature'`)
4. Push to the branch (`git push origin feature/amazing-feature`)
5. Open a Pull Request

## Commit Message Format

We follow the [Conventional Commits](https://www.conventionalcommits.org/) specification:

```
<type>(<scope>): <description>

[optional body]

[optional footer]
```

Types:
- `feat`: New feature
- `fix`: Bug fix
- `docs`: Documentation changes
- `style`: Code style changes
- `refactor`: Code refactoring
- `test`: Test-related changes
- `chore`: Maintenance tasks

## Testing

- Run tests: `pnpm test`
- Run tests with coverage: `pnpm test:coverage`

## Documentation

- Update relevant documentation when adding new features
- Follow the existing documentation style
- Include examples where appropriate

## Questions?

Feel free to open an issue or reach out to the maintainers for any questions.
Loading