Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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: 0 additions & 1 deletion Sources/Dumpling/dumpling_fuzzilli.patch
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ index 05e5dc1..540b552 100644

.target(name: "FuzzilliCli",
dependencies: ["Fuzzilli"]),
-
- .target(name: "FuzzILTool",
+
+ .target(name: "RelateTool",
Expand Down
86 changes: 1 addition & 85 deletions Sources/FatherOfGeorge/BaseAgent.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
from smolagents import LiteLLMModel, ToolCallingAgent


class Agent(ABC):
class Agent(ABC): #a
"""Base class for AI agents."""

def __init__(self, model: LiteLLMModel, api_key: str = None, anthropic_api_key: str = None):
Expand Down Expand Up @@ -115,87 +115,3 @@ def _create_task_prompt(self, task_description: str, context: dict = None) -> st
prompt += "\n"

return prompt


# Tool definitions for different agent types
def get_manager_tools():
"""Tools available to manager agents."""
return [
# TODO: Add manager-specific tools
# - orchestrate_subagents
# - collect_results
# - make_decisions
# - validate_outputs
]

def get_code_analysis_tools():
"""Tools available to code analysis agents."""
return [
# TODO: Add code analysis tools
# - analyze_syntax
# - analyze_semantics
# - extract_patterns
# - identify_vulnerabilities
]

def get_retrieval_tools():
"""Tools available to retrieval agents."""
return [
# TODO: Add retrieval tools
# - query_rag_db
# - search_vector_db
# - retrieve_context
# - validate_information
]

def get_v8_search_tools():
"""Tools available to V8 search agents."""
return [
# TODO: Add V8 search tools
# - fuzzy_find
# - regex_search
# - compile_with_clang
# - test_with_python
# - view_call_graph
# - web_search
]

def get_program_builder_tools():
"""Tools available to program builder agents."""
return [
# TODO: Add program builder tools
# - query_postgres_db
# - generate_seed_program
# - combine_contexts
# - validate_syntax
]

def get_corpus_generation_tools():
"""Tools available to corpus generation agents."""
return [
# TODO: Add corpus generation tools
# - validate_syntax
# - validate_semantics
# - test_program
# - evaluate_interestingness
]

def get_runtime_analysis_tools():
"""Tools available to runtime analysis agents."""
return [
# TODO: Add runtime analysis tools
# - analyze_execution_state
# - check_coverage
# - evaluate_flags
# - determine_seed_quality
]

def get_validation_tools():
"""Tools available to validation agents."""
return [
# TODO: Add validation tools
# - validate_corpus
# - check_db_integrity
# - verify_results
# - quality_assurance
]
Original file line number Diff line number Diff line change
@@ -1,33 +1,34 @@
#!/usr/bin/env python3
'''
Child of the Father of George. Thus, George.
Ethiopian BG
L1 Manager Agent - Verification and Testing Coordinator
'''

from smolagents import LiteLLMModel, ToolCallingAgent
from BaseAgent import Agent, get_manager_tools, get_corpus_generation_tools, get_runtime_analysis_tools, get_validation_tools, get_code_analysis_tools
from BaseAgent import Agent


class George(Agent):
class EBG(Agent): #a
"""Verify and test seeds."""

def setup_agents(self):
# L3 Worker: Code Analyzer (under RuntimeAnalyzer)
self.agents['code_analyzer'] = ToolCallingAgent(
name="CodeAnalyzer",
description="L3 Worker responsible for analyzing code patterns, vulnerabilities, and specific components for runtime analysis",
tools=get_code_analysis_tools(),
tools=[],
model=LiteLLMModel(model_id="gpt-5", api_key=self.api_key),
managed_agents=[],
max_steps=8, # Fewer steps than L1 CodeAnalyzer
planning_interval=None,
)
#self.agents['vuln_analysis_agent'].prompt_templates["system_prompt"] = self.get_prompt("code_analysis_prompt") # and similar for other agents

# L2 Worker: Corpus Generator (under George)
self.agents['corpus_generator'] = ToolCallingAgent(
name="CorpusGenerator",
description="L2 Worker responsible for generating seeds from the corpus and validating syntax/semantics",
tools=get_corpus_generation_tools(),
tools=[],
model=LiteLLMModel(model_id="gpt-5", api_key=self.api_key),
managed_agents=[],
max_steps=10,
Expand All @@ -38,7 +39,7 @@ def setup_agents(self):
self.agents['runtime_analyzer'] = ToolCallingAgent(
name="RuntimeAnalyzer",
description="L2 Manager responsible for analyzing program runtime, coverage, and execution state",
tools=get_runtime_analysis_tools(),
tools=[],
model=LiteLLMModel(model_id="gpt-5", api_key=self.api_key),
managed_agents=[
self.agents['code_analyzer']
Expand All @@ -51,7 +52,7 @@ def setup_agents(self):
self.agents['corpus_validator'] = ToolCallingAgent(
name="CorpusValidator",
description="L2 Worker responsible for validating corpus integrity and quality",
tools=get_validation_tools(),
tools=[],
model=LiteLLMModel(model_id="gpt-5", api_key=self.api_key),
managed_agents=[],
max_steps=8,
Expand All @@ -62,7 +63,7 @@ def setup_agents(self):
self.agents['db_analyzer'] = ToolCallingAgent(
name="DBAnalyzer",
description="L2 Worker responsible for analyzing PostgreSQL database for corpus, flags, coverage, and execution state",
tools=get_validation_tools(), # Reusing validation tools for DB analysis
tools=[], # Reusing validation tools for DB analysis
model=LiteLLMModel(model_id="gpt-5", api_key=self.api_key),
managed_agents=[],
max_steps=8,
Expand All @@ -73,7 +74,7 @@ def setup_agents(self):
self.agents['george_foreman'] = ToolCallingAgent(
name="GeorgeForeman",
description="L1 Manager responsible for verifying JavaScript programs for correctness and testing them to evaluate interestingness",
tools=get_manager_tools(),
tools=[],
model=LiteLLMModel(model_id="gpt-5-mini", api_key=self.api_key),
managed_agents=[
self.agents['corpus_generator'],
Expand Down
32 changes: 17 additions & 15 deletions Sources/FatherOfGeorge/FoG.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,28 +3,30 @@


from smolagents import LiteLLMModel, ToolCallingAgent
from BaseAgent import Agent, get_manager_tools, get_code_analysis_tools, get_program_builder_tools, get_retrieval_tools, get_v8_search_tools
from GeorgeForeman import George
from pathlib import Path
from BaseAgent import Agent
from EBG import EBG
from pathlib import Path #a


class Father(Agent):
def setup_agents(self):

# L2 Worker: George Foreman

self.agents['george_foreman'] = George(
model=self.model,
api_key=self.api_key,
anthropic_api_key=self.anthropic_api_key
# L2 Worker: EBG
self.agents['george_foreman'] = ToolCallingAgent(
name="GeorgeForeman",
description="L2 Worker responsible for generating JavaScript programs and fuzzing corpus",
tools=[],
model=LiteLLMModel(model_id="gpt-5", api_key=self.api_key),
managed_agents=[],
max_steps=10,
planning_interval=None,
)

# L2 Worker: Reviwer of Code (under CodeAnalyzer)

self.agents['reviewer_of_code'] = ToolCallingAgent(
name="ReviewerOfCode",
description="L2 Worker responsible for reviewing code from various sources using RAG database",
tools=get_retrieval_tools(),
tools=[],
model=LiteLLMModel(model_id="gpt-5", api_key=self.api_key),
managed_agents=[
self.agents['george_foreman']
Expand All @@ -39,7 +41,7 @@ def setup_agents(self):
self.agents['v8_search'] = ToolCallingAgent(
name="V8Search",
description="L2 Worker responsible for searching V8 source code using fuzzy find, regex, and compilation tools",
tools=get_v8_search_tools(),
tools=[],
model=LiteLLMModel(model_id="gpt-5", api_key=self.api_key),
managed_agents=[],
max_steps=10,
Expand All @@ -51,7 +53,7 @@ def setup_agents(self):
self.agents['code_analyzer'] = ToolCallingAgent(
name="CodeAnalyzer",
description="L1 Manager responsible for analyzing code and coordinating retrieval and V8 search operations",
tools=get_code_analysis_tools(),
tools=[],
model=LiteLLMModel(model_id="gpt-5", api_key=self.api_key),
managed_agents=[
self.agents['retriever_of_code'],
Expand All @@ -65,7 +67,7 @@ def setup_agents(self):
self.agents['program_builder'] = ToolCallingAgent(
name="ProgramBuilder",
description="L1 Manager responsible for building program templates using corpus and context",
tools=get_program_builder_tools(),
tools=[],
model=LiteLLMModel(model_id="gpt-5", api_key=self.api_key),
managed_agents=[
self.agents['george_foreman']
Expand All @@ -78,7 +80,7 @@ def setup_agents(self):
self.agents['father_of_george'] = ToolCallingAgent(
name="FatherOfGeorge",
description="L0 Root Manager responsible for orchestrating code analysis and program building operations",
tools=get_manager_tools(),
tools=[],
model=LiteLLMModel(model_id="gpt-5-mini", api_key=self.api_key),
managed_agents=[
self.agents['code_analyzer'],
Expand Down
11 changes: 11 additions & 0 deletions Sources/FatherOfGeorge/prompts/FoG_prompt.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Role and Objective

# Instructions
STAGE 1
...
CRITICAL RULES:

CORRECT WORKFLOW:


f
10 changes: 10 additions & 0 deletions Sources/FatherOfGeorge/prompts/ebg_promp
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Role and Objective

# Instructions
STAGE 1
...
CRITICAL RULES:

CORRECT WORKFLOW:

f
Empty file.