il2cpp-dump-analyzer-mcp
Version:
Agentic RAG system for analyzing IL2CPP dump.cs files from Unity games
81 lines (80 loc) • 2.75 kB
TypeScript
import { IL2CPPVectorStore } from '../embeddings/vector-store';
import { IHashManager } from '../utils/supabase-hash-manager';
/**
* Manages the indexing process for IL2CPP dump files
*/
export declare class IL2CPPIndexer {
private readonly chunkSize;
private readonly chunkOverlap;
private readonly model?;
private parser;
private chunker;
private vectorStore;
private hashManager;
constructor(chunkSize?: number, chunkOverlap?: number, model?: string | undefined, hashFilePath?: string);
/**
* Index an IL2CPP dump file
* @param filePath Path to the dump.cs file
* @param progressCallback Optional callback for progress updates
* @param forceReprocess Force reprocessing even if file was already processed
* @returns The vector store with indexed content
*/
indexFile(filePath: string, progressCallback?: (progress: number, message: string) => void, forceReprocess?: boolean): Promise<IL2CPPVectorStore>;
/**
* Process a batch of classes to create chunks
* @param classes Batch of classes to process
* @returns Array of code chunks
*/
private processClassBatch;
/**
* Get the vector store instance
* @returns Vector store instance
*/
getVectorStore(): IL2CPPVectorStore;
/**
* Get the hash manager instance
* @returns Hash manager instance
*/
getHashManager(): IHashManager;
/**
* Check if a file has been processed before
* @param filePath Path to the dump.cs file
* @returns true if file was already processed
*/
isFileProcessed(filePath: string): boolean;
/**
* Check if a file has been processed before (async version)
* @param filePath Path to the dump.cs file
* @returns Promise that resolves to true if file was already processed
*/
isFileProcessedAsync(filePath: string): Promise<boolean>;
/**
* Get the hash of a file
* @param filePath Path to the dump.cs file
* @returns SHA-256 hash of the file
*/
getFileHash(filePath: string): string;
/**
* Remove a file from the processed list (to allow reprocessing)
* @param filePath Path to the dump.cs file
* @returns true if hash was removed
*/
removeFileFromProcessed(filePath: string): boolean;
/**
* Clear all processed file hashes
*/
clearAllProcessedFiles(): void;
/**
* Get information about processed files
* @returns Object with hash storage info
*/
getProcessedFilesInfo(): {
hashFilePath?: string;
processedCount: number;
};
/**
* Get all processed file hashes
* @returns Array of all stored hashes
*/
getAllProcessedHashes(): string[];
}