File tree Expand file tree Collapse file tree
src/codegen/extensions/tools Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -22,6 +22,9 @@ class ViewFileObservation(Observation):
2222 content : str = Field (
2323 description = "Content of the file" ,
2424 )
25+ raw_content : str = Field (
26+ description = "Raw content of the file" ,
27+ )
2528 line_count : Optional [int ] = Field (
2629 default = None ,
2730 description = "Number of lines in the file" ,
@@ -64,7 +67,7 @@ def render(self, tool_call_id: str) -> ToolMessage:
6467 "filepath" : self .filepath ,
6568 "start_line" : self .start_line ,
6669 "end_line" : self .end_line ,
67- "content" : self .content ,
70+ "content" : self .raw_content ,
6871 "total_lines" : self .line_count ,
6972 "has_more" : self .has_more ,
7073 "max_lines_per_page" : self .max_lines_per_page ,
@@ -173,6 +176,7 @@ def view_file(
173176 status = "success" ,
174177 filepath = file .filepath ,
175178 content = content ,
179+ raw_content = file .content ,
176180 line_count = total_lines ,
177181 )
178182
You can’t perform that action at this time.
0 commit comments