mirror of
https://github.com/Pythagora-io/gpt-pilot.git
synced 2026-01-09 21:27:53 -05:00
address pr feedback
This commit is contained in:
@@ -43,5 +43,5 @@ DB_PASSWORD=
|
||||
# Set extra buffer to wait on top of detected retry time when rate limmit is hit. defaults to 6
|
||||
# RATE_LIMIT_EXTRA_BUFFER=
|
||||
|
||||
# Only send task-relevant files to the LLM. Disabled by default until we're sure it works correctly.
|
||||
# FILTER_RELEVANT_FILES=false
|
||||
# Only send task-relevant files to the LLM. Enabled by default; uncomment and set this to "false" to disable.
|
||||
# FILTER_RELEVANT_FILES=true
|
||||
|
||||
@@ -544,7 +544,7 @@ LIST_RELEVANT_FILES = {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string",
|
||||
"description": "Path to the file that is relevant for the current task."
|
||||
"description": "Path to the file that is relevant for the current task, relative to the project root."
|
||||
},
|
||||
}
|
||||
},
|
||||
@@ -562,15 +562,16 @@ DESCRIBE_FILE = {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"summary": {
|
||||
"type": "string",
|
||||
"description": "Describe in detail the functionality being defined or implemented in this file. Be as detailed as possible."
|
||||
"type": "string",
|
||||
"description": "Describe in detail the functionality being defined or implemented in this file. Be as detailed as possible."
|
||||
},
|
||||
"references": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "List of file references."
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string",
|
||||
"description": "Path to a file that is referenced in the current file, relative to the project root.",
|
||||
},
|
||||
"description": "List of file references."
|
||||
}
|
||||
},
|
||||
"required": ["summary", "references"],
|
||||
|
||||
@@ -383,7 +383,7 @@ class Project:
|
||||
|
||||
:returns: A dictionary of file summaries, or None if file filtering is not enabled.
|
||||
"""
|
||||
if os.getenv('FILTER_RELEVANT_FILES', '').lower().strip() not in ['true', '1', 'yes', 'on']:
|
||||
if os.getenv('FILTER_RELEVANT_FILES', '').lower().strip() in ['false', '0', 'no', 'off']:
|
||||
return None
|
||||
|
||||
files = self.get_all_database_files()
|
||||
|
||||
@@ -1125,7 +1125,7 @@ class Developer(Agent):
|
||||
if not file_summaries:
|
||||
return None
|
||||
|
||||
if os.getenv('FILTER_RELEVANT_FILES', '').lower().strip() not in ['true', '1', 'yes', 'on']:
|
||||
if os.getenv('FILTER_RELEVANT_FILES', '').lower().strip() in ['false', '0', 'no', 'off']:
|
||||
return None
|
||||
|
||||
convo = AgentConvo(self)
|
||||
|
||||
@@ -45,7 +45,7 @@ def _get_describe_messages(fpath: str, content: str) -> list[dict[str, str]]:
|
||||
|
||||
|
||||
def describe_file(project, fpath: str, content: str) -> str:
|
||||
if os.getenv('FILTER_RELEVANT_FILES', '').lower().strip() not in ['true', '1', 'yes', 'on']:
|
||||
if os.getenv('FILTER_RELEVANT_FILES', '').lower().strip() in ['false', '0', 'no', 'off']:
|
||||
return ''
|
||||
|
||||
model_name = os.getenv("MODEL_NAME")
|
||||
|
||||
Reference in New Issue
Block a user