| Pokey Rule | e7c9a44 | 2025-04-25 20:02:22 +0100 | [diff] [blame] | 1 | import { AgentMessage, State } from "../types"; |
| Pokey Rule | 8cac59a | 2025-04-24 12:21:19 +0100 | [diff] [blame] | 2 | |
| 3 | export const initialMessages: AgentMessage[] = [ |
| 4 | { |
| 5 | type: "user", |
| 6 | end_of_turn: false, |
| 7 | content: |
| 8 | "add a line to dummy.txt. Doesn't matter what it is and don't bother running tests it's just a dummy repo. Please commit afterward", |
| 9 | timestamp: "2025-04-24T10:32:00.679873+01:00", |
| 10 | conversation_id: "", |
| 11 | idx: 0, |
| 12 | }, |
| 13 | { |
| 14 | type: "agent", |
| 15 | end_of_turn: false, |
| 16 | content: |
| 17 | "I'll help you add a line to dummy.txt and commit the change. Let me first check if this file exists and create it if needed.", |
| 18 | tool_calls: [ |
| 19 | { |
| 20 | name: "title", |
| 21 | input: '{"title":"Add a line to dummy.txt and commit the change"}', |
| 22 | tool_call_id: "toolu_01HSQ8xb9Ba8oP1gJPv1eD2s", |
| 23 | }, |
| 24 | ], |
| 25 | timestamp: "2025-04-24T10:32:03.988439+01:00", |
| 26 | conversation_id: "37s-g6xg", |
| 27 | usage: { |
| 28 | input_tokens: 4, |
| 29 | cache_creation_input_tokens: 2228, |
| 30 | cache_read_input_tokens: 0, |
| 31 | output_tokens: 92, |
| 32 | cost_usd: 0.009747, |
| 33 | }, |
| 34 | start_time: "2025-04-24T10:32:00.680125+01:00", |
| 35 | end_time: "2025-04-24T10:32:03.988434+01:00", |
| 36 | elapsed: 3308355125, |
| 37 | idx: 1, |
| 38 | }, |
| 39 | { |
| 40 | type: "tool", |
| 41 | end_of_turn: false, |
| 42 | content: "", |
| 43 | tool_name: "title", |
| 44 | input: '{"title":"Add a line to dummy.txt and commit the change"}', |
| 45 | tool_result: "Title set to: Add a line to dummy.txt and commit the change", |
| 46 | tool_call_id: "toolu_01HSQ8xb9Ba8oP1gJPv1eD2s", |
| 47 | timestamp: "2025-04-24T10:32:03.988567+01:00", |
| 48 | conversation_id: "37s-g6xg", |
| 49 | start_time: "2025-04-24T10:32:03.988553+01:00", |
| 50 | end_time: "2025-04-24T10:32:03.988566+01:00", |
| 51 | elapsed: 13500, |
| 52 | idx: 2, |
| 53 | }, |
| 54 | { |
| 55 | type: "agent", |
| 56 | end_of_turn: false, |
| 57 | content: "", |
| 58 | tool_calls: [ |
| 59 | { |
| 60 | name: "bash", |
| 61 | input: '{"command":"ls -la"}', |
| 62 | tool_call_id: "toolu_01RtkhetY8bqC6U1QBfVbukS", |
| 63 | }, |
| 64 | ], |
| 65 | timestamp: "2025-04-24T10:32:06.146332+01:00", |
| 66 | conversation_id: "37s-g6xg", |
| 67 | usage: { |
| 68 | input_tokens: 6, |
| 69 | cache_creation_input_tokens: 116, |
| 70 | cache_read_input_tokens: 2228, |
| 71 | output_tokens: 54, |
| 72 | cost_usd: 0.0019314, |
| 73 | }, |
| 74 | start_time: "2025-04-24T10:32:04.007226+01:00", |
| 75 | end_time: "2025-04-24T10:32:06.146325+01:00", |
| 76 | elapsed: 2139128375, |
| 77 | idx: 3, |
| 78 | }, |
| 79 | { |
| 80 | type: "tool", |
| 81 | end_of_turn: false, |
| 82 | content: "", |
| 83 | tool_name: "bash", |
| 84 | input: '{"command":"ls -la"}', |
| 85 | tool_result: |
| 86 | "total 1712\ndrwxr-xr-x 29 pokey staff 928 Apr 15 13:06 .\ndrwxr-xr-x 397 pokey staff 12704 Apr 23 09:53 ..\n-rw-r--r--@ 1 pokey staff 292 Jan 8 2024 .editorconfig\ndrwxr-xr-x 17 pokey staff 544 Apr 24 10:32 .git\ndrwxr-xr-x@ 3 pokey staff 96 Jan 8 2024 .github\n-rw-r--r--@ 1 pokey staff 777 Jan 8 2024 .gitignore\n-rw-r--r--@ 1 pokey staff 0 Apr 15 13:06 .PROMPT_DRAFT.md\n-rw------- 1 pokey staff 11811 Oct 4 2022 .tags\n-rw-r--r--@ 1 pokey staff 762 Jan 8 2024 .travis.yml\ndrwxr-xr-x 3 pokey staff 96 Apr 9 10:51 .vscode\n-rw-r--r--@ 1 pokey staff 156 Jan 8 2024 AUTHORS.rst\n-rw-r--r--@ 1 pokey staff 3249 Jan 8 2024 CONTRIBUTING.rst\ndrwxr-xr-x@ 12 pokey staff 384 Jan 8 2024 docs\n-rw-r--r-- 1 pokey staff 6644 Apr 23 15:31 dummy.txt\n-rw-r--r--@ 1 pokey staff 89 Jan 8 2024 HISTORY.rst\n-rw-r--r--@ 1 pokey staff 1070 Jan 8 2024 LICENSE\n-rw-r--r--@ 1 pokey staff 2303 Jan 8 2024 Makefile\n-rw-r--r--@ 1 pokey staff 264 Jan 8 2024 MANIFEST.in\n-rw-r--r-- 1 pokey staff 794413 Mar 7 2017 myVim.log\n-rw-r--r--@ 1 pokey staff 1043 Apr 8 12:21 README.rst\n-rw-r--r--@ 1 pokey staff 145 Jan 8 2024 requirements_dev.txt\n-rw-r--r--@ 1 pokey staff 342 Jan 8 2024 setup.cfg\n-rw-r--r--@ 1 pokey staff 1559 Jan 8 2024 setup.py\ndrwxr-xr-x 6 pokey staff 192 Jan 8 2024 spaghetti\ndrwxr-xr-x 9 pokey staff 288 Feb 26 2017 spaghetti.egg-info\ndrwxr-xr-x@ 5 pokey staff 160 Apr 4 19:07 tests\n-rw-r--r--@ 1 pokey staff 430 Jan 8 2024 tox.ini\n-rw-r--r--@ 1 pokey staff 3753 Jan 8 2024 travis_pypi_setup.py\ndrwxr-xr-x 2 pokey staff 64 Mar 11 2017 UltiSnips\n", |
| 87 | tool_call_id: "toolu_01RtkhetY8bqC6U1QBfVbukS", |
| 88 | timestamp: "2025-04-24T10:32:06.176176+01:00", |
| 89 | conversation_id: "37s-g6xg", |
| 90 | start_time: "2025-04-24T10:32:06.146414+01:00", |
| 91 | end_time: "2025-04-24T10:32:06.176175+01:00", |
| 92 | elapsed: 29760750, |
| 93 | idx: 4, |
| 94 | }, |
| 95 | { |
| 96 | type: "agent", |
| 97 | end_of_turn: false, |
| 98 | content: |
| 99 | "I see that dummy.txt already exists. Let me add a new line to it.", |
| 100 | tool_calls: [ |
| 101 | { |
| 102 | name: "patch", |
| 103 | input: |
| 104 | '{"path":"/Users/pokey/src/spaghetti/dummy.txt","patches":[{"operation":"append_eof","newText":"\\nAdding a new dummy line here - requested change"}]}', |
| 105 | tool_call_id: "toolu_01KjY2a2MWhfvwy6Pmci8SX2", |
| 106 | }, |
| 107 | ], |
| 108 | timestamp: "2025-04-24T10:32:09.724348+01:00", |
| 109 | conversation_id: "37s-g6xg", |
| 110 | usage: { |
| 111 | input_tokens: 6, |
| 112 | cache_creation_input_tokens: 970, |
| 113 | cache_read_input_tokens: 2344, |
| 114 | output_tokens: 141, |
| 115 | cost_usd: 0.0064737, |
| 116 | }, |
| 117 | start_time: "2025-04-24T10:32:06.195746+01:00", |
| 118 | end_time: "2025-04-24T10:32:09.724335+01:00", |
| 119 | elapsed: 3528638042, |
| 120 | idx: 5, |
| 121 | }, |
| 122 | { |
| 123 | type: "tool", |
| 124 | end_of_turn: false, |
| 125 | content: "", |
| 126 | tool_name: "patch", |
| 127 | input: |
| 128 | '{"path":"/Users/pokey/src/spaghetti/dummy.txt","patches":[{"operation":"append_eof","newText":"\\nAdding a new dummy line here - requested change"}]}', |
| 129 | tool_result: "- Applied all patches\n", |
| 130 | tool_call_id: "toolu_01KjY2a2MWhfvwy6Pmci8SX2", |
| 131 | timestamp: "2025-04-24T10:32:09.728267+01:00", |
| 132 | conversation_id: "37s-g6xg", |
| 133 | start_time: "2025-04-24T10:32:09.725039+01:00", |
| 134 | end_time: "2025-04-24T10:32:09.728265+01:00", |
| 135 | elapsed: 3225875, |
| 136 | idx: 6, |
| 137 | }, |
| 138 | { |
| 139 | type: "agent", |
| 140 | end_of_turn: false, |
| 141 | content: "Now let me commit this change:", |
| 142 | tool_calls: [ |
| 143 | { |
| 144 | name: "bash", |
| 145 | input: |
| 146 | '{"command":"GIT_AUTHOR_NAME=\\"Pokey Rule\\" GIT_AUTHOR_EMAIL=\\"755842+pokey@users.noreply.github.com\\" git add dummy.txt && git commit -m \\"Add a new line to dummy.txt\\" -m \\"Co-Authored-By: sketch\\" -m \\"Add a line to dummy.txt. Doesn\'t matter what it is and don\'t bother running tests it\'s just a dummy repo.\\""}', |
| 147 | tool_call_id: "toolu_01NQXuuU4JdUHn29S35oGLxF", |
| 148 | }, |
| 149 | ], |
| 150 | timestamp: "2025-04-24T10:32:13.306331+01:00", |
| 151 | conversation_id: "37s-g6xg", |
| 152 | usage: { |
| 153 | input_tokens: 6, |
| 154 | cache_creation_input_tokens: 146, |
| 155 | cache_read_input_tokens: 3314, |
| 156 | output_tokens: 160, |
| 157 | cost_usd: 0.0039597, |
| 158 | }, |
| 159 | start_time: "2025-04-24T10:32:09.76053+01:00", |
| 160 | end_time: "2025-04-24T10:32:13.306203+01:00", |
| 161 | elapsed: 3545723083, |
| 162 | idx: 7, |
| 163 | }, |
| 164 | { |
| 165 | type: "tool", |
| 166 | end_of_turn: false, |
| 167 | content: "", |
| 168 | tool_name: "bash", |
| 169 | input: |
| 170 | '{"command":"GIT_AUTHOR_NAME=\\"Pokey Rule\\" GIT_AUTHOR_EMAIL=\\"755842+pokey@users.noreply.github.com\\" git add dummy.txt && git commit -m \\"Add a new line to dummy.txt\\" -m \\"Co-Authored-By: sketch\\" -m \\"Add a line to dummy.txt. Doesn\'t matter what it is and don\'t bother running tests it\'s just a dummy repo.\\""}', |
| 171 | tool_result: |
| 172 | "branchless: processing 2 updates: branch main, ref HEAD\nbranchless: processed commit: 898178a Add a new line to dummy.txt\n[main 898178a] Add a new line to dummy.txt\n 1 file changed, 2 insertions(+), 1 deletion(-)\n", |
| 173 | tool_call_id: "toolu_01NQXuuU4JdUHn29S35oGLxF", |
| 174 | timestamp: "2025-04-24T10:32:13.652683+01:00", |
| 175 | conversation_id: "37s-g6xg", |
| 176 | start_time: "2025-04-24T10:32:13.307345+01:00", |
| 177 | end_time: "2025-04-24T10:32:13.652678+01:00", |
| 178 | elapsed: 345337875, |
| 179 | idx: 8, |
| 180 | }, |
| 181 | { |
| 182 | type: "commit", |
| 183 | end_of_turn: false, |
| 184 | content: "", |
| 185 | commits: [ |
| 186 | { |
| 187 | hash: "898178a0c6681ce2b641cbe8994c22ed8bbb7dd7", |
| 188 | subject: "Add a new line to dummy.txt", |
| 189 | body: "Co-Authored-By: sketch\n\nAdd a line to dummy.txt. Doesn't matter what it is and don't bother running tests it's just a dummy repo.", |
| 190 | }, |
| 191 | ], |
| 192 | timestamp: "2025-04-24T10:32:13.690825+01:00", |
| 193 | conversation_id: "", |
| 194 | idx: 9, |
| 195 | }, |
| 196 | { |
| 197 | type: "agent", |
| 198 | end_of_turn: false, |
| 199 | content: "", |
| 200 | tool_calls: [ |
| 201 | { |
| 202 | name: "done", |
| 203 | input: |
| 204 | '{"checklist_items":{"git_commit":{"status":"yes","description":"Created a git commit for the code changes with the appropriate commit message that includes \'Co-Authored-By: sketch\' and the original user prompt."},"wrote_tests":{"status":"not applicable","description":"No functional code was changed, just added a line to a dummy file."},"passes_tests":{"status":"not applicable","description":"User explicitly mentioned not to run tests as this is just a dummy repo."},"code_reviewed":{"status":"not applicable","description":"The change was trivial - just adding a line to a dummy.txt file."}}}', |
| 205 | tool_call_id: "toolu_01YMBDmBoCcE5tfZvbXAgWEa", |
| 206 | }, |
| 207 | ], |
| 208 | timestamp: "2025-04-24T10:32:19.07007+01:00", |
| 209 | conversation_id: "37s-g6xg", |
| 210 | usage: { |
| 211 | input_tokens: 6, |
| 212 | cache_creation_input_tokens: 244, |
| 213 | cache_read_input_tokens: 3460, |
| 214 | output_tokens: 241, |
| 215 | cost_usd: 0.005586, |
| 216 | }, |
| 217 | start_time: "2025-04-24T10:32:13.74753+01:00", |
| 218 | end_time: "2025-04-24T10:32:19.070058+01:00", |
| 219 | elapsed: 5322601792, |
| 220 | idx: 10, |
| 221 | }, |
| 222 | { |
| 223 | type: "tool", |
| 224 | end_of_turn: false, |
| 225 | content: "", |
| 226 | tool_name: "done", |
| 227 | input: |
| 228 | '{"checklist_items":{"git_commit":{"status":"yes","description":"Created a git commit for the code changes with the appropriate commit message that includes \'Co-Authored-By: sketch\' and the original user prompt."},"wrote_tests":{"status":"not applicable","description":"No functional code was changed, just added a line to a dummy file."},"passes_tests":{"status":"not applicable","description":"User explicitly mentioned not to run tests as this is just a dummy repo."},"code_reviewed":{"status":"not applicable","description":"The change was trivial - just adding a line to a dummy.txt file."}}}', |
| 229 | tool_result: |
| 230 | "codereview tool has not been run for commit 898178a0c6681ce2b641cbe8994c22ed8bbb7dd7", |
| 231 | tool_error: true, |
| 232 | tool_call_id: "toolu_01YMBDmBoCcE5tfZvbXAgWEa", |
| 233 | timestamp: "2025-04-24T10:32:19.121365+01:00", |
| 234 | conversation_id: "37s-g6xg", |
| 235 | start_time: "2025-04-24T10:32:19.070249+01:00", |
| 236 | end_time: "2025-04-24T10:32:19.121358+01:00", |
| 237 | elapsed: 51109583, |
| 238 | idx: 11, |
| 239 | }, |
| 240 | { |
| 241 | type: "agent", |
| 242 | end_of_turn: false, |
| 243 | content: "Let me run a code review as required:", |
| 244 | tool_calls: [ |
| 245 | { |
| 246 | name: "codereview", |
| 247 | input: "{}", |
| 248 | tool_call_id: "toolu_01Fgg5vaURskyxGcbwHoBu7z", |
| 249 | }, |
| 250 | ], |
| 251 | timestamp: "2025-04-24T10:32:21.918149+01:00", |
| 252 | conversation_id: "37s-g6xg", |
| 253 | usage: { |
| 254 | input_tokens: 7, |
| 255 | cache_creation_input_tokens: 253, |
| 256 | cache_read_input_tokens: 3704, |
| 257 | output_tokens: 54, |
| 258 | cost_usd: 0.0028909499999999998, |
| 259 | }, |
| 260 | start_time: "2025-04-24T10:32:19.14049+01:00", |
| 261 | end_time: "2025-04-24T10:32:21.918133+01:00", |
| 262 | elapsed: 2777681917, |
| 263 | idx: 12, |
| 264 | }, |
| 265 | { |
| 266 | type: "tool", |
| 267 | end_of_turn: false, |
| 268 | content: "", |
| 269 | tool_name: "codereview", |
| 270 | input: "{}", |
| 271 | tool_result: "OK", |
| 272 | tool_call_id: "toolu_01Fgg5vaURskyxGcbwHoBu7z", |
| 273 | timestamp: "2025-04-24T10:32:22.516658+01:00", |
| 274 | conversation_id: "37s-g6xg", |
| 275 | start_time: "2025-04-24T10:32:21.918261+01:00", |
| 276 | end_time: "2025-04-24T10:32:22.516654+01:00", |
| 277 | elapsed: 598402125, |
| 278 | idx: 13, |
| 279 | }, |
| 280 | { |
| 281 | type: "agent", |
| 282 | end_of_turn: false, |
| 283 | content: "Now let me try the done call again:", |
| 284 | tool_calls: [ |
| 285 | { |
| 286 | name: "done", |
| 287 | input: |
| 288 | '{"checklist_items":{"git_commit":{"status":"yes","description":"Created a git commit for the code changes with the appropriate commit message that includes \'Co-Authored-By: sketch\' and the original user prompt."},"wrote_tests":{"status":"not applicable","description":"No functional code was changed, just added a line to a dummy file."},"passes_tests":{"status":"not applicable","description":"User explicitly mentioned not to run tests as this is just a dummy repo."},"code_reviewed":{"status":"yes","description":"Code review completed and no issues found. The change was trivial - just adding a line to a dummy.txt file."}}}', |
| 289 | tool_call_id: "toolu_016TBxz5Ma8y3if3rY4DZBXE", |
| 290 | }, |
| 291 | ], |
| 292 | timestamp: "2025-04-24T10:32:26.926407+01:00", |
| 293 | conversation_id: "37s-g6xg", |
| 294 | usage: { |
| 295 | input_tokens: 6, |
| 296 | cache_creation_input_tokens: 60, |
| 297 | cache_read_input_tokens: 3957, |
| 298 | output_tokens: 217, |
| 299 | cost_usd: 0.0046851, |
| 300 | }, |
| 301 | start_time: "2025-04-24T10:32:22.534359+01:00", |
| 302 | end_time: "2025-04-24T10:32:26.926391+01:00", |
| 303 | elapsed: 4392093250, |
| 304 | idx: 14, |
| 305 | }, |
| 306 | { |
| 307 | type: "tool", |
| 308 | end_of_turn: false, |
| 309 | content: "", |
| 310 | tool_name: "done", |
| 311 | input: |
| 312 | '{"checklist_items":{"git_commit":{"status":"yes","description":"Created a git commit for the code changes with the appropriate commit message that includes \'Co-Authored-By: sketch\' and the original user prompt."},"wrote_tests":{"status":"not applicable","description":"No functional code was changed, just added a line to a dummy file."},"passes_tests":{"status":"not applicable","description":"User explicitly mentioned not to run tests as this is just a dummy repo."},"code_reviewed":{"status":"yes","description":"Code review completed and no issues found. The change was trivial - just adding a line to a dummy.txt file."}}}', |
| 313 | tool_result: |
| 314 | "Please ask the user to review your work. Be concise - users are more likely to read shorter comments.", |
| 315 | tool_call_id: "toolu_016TBxz5Ma8y3if3rY4DZBXE", |
| 316 | timestamp: "2025-04-24T10:32:26.978771+01:00", |
| 317 | conversation_id: "37s-g6xg", |
| 318 | start_time: "2025-04-24T10:32:26.92661+01:00", |
| 319 | end_time: "2025-04-24T10:32:26.978758+01:00", |
| 320 | elapsed: 52149125, |
| 321 | idx: 15, |
| 322 | }, |
| 323 | { |
| 324 | type: "agent", |
| Pokey Rule | 563d6b3 | 2025-04-24 16:17:40 +0100 | [diff] [blame] | 325 | end_of_turn: true, |
| Pokey Rule | 8cac59a | 2025-04-24 12:21:19 +0100 | [diff] [blame] | 326 | content: |
| 327 | 'I\'ve completed your request:\n\n1. Added a new line to dummy.txt: "Adding a new dummy line here - requested change"\n2. Created a git commit with the change using the specified author information\n3. Included "Co-Authored-By: sketch" in the commit message as required\n\nThe change has been successfully committed to the repository. Is there anything else you\'d like me to help with?', |
| 328 | timestamp: "2025-04-24T10:32:29.072661+01:00", |
| 329 | conversation_id: "37s-g6xg", |
| 330 | usage: { |
| 331 | input_tokens: 5, |
| 332 | cache_creation_input_tokens: 250, |
| 333 | cache_read_input_tokens: 4017, |
| 334 | output_tokens: 92, |
| 335 | cost_usd: 0.0035376, |
| 336 | }, |
| 337 | start_time: "2025-04-24T10:32:26.99749+01:00", |
| 338 | end_time: "2025-04-24T10:32:29.072654+01:00", |
| 339 | elapsed: 2075193375, |
| 340 | turnDuration: 28393844125, |
| 341 | idx: 16, |
| 342 | }, |
| 343 | ]; |
| 344 | |
| 345 | export const initialState: State = { |
| 346 | message_count: initialMessages.length, |
| 347 | total_usage: { |
| 348 | start_time: "2025-04-24T10:32:00.679057+01:00", |
| 349 | messages: 8, |
| 350 | input_tokens: 46, |
| 351 | output_tokens: 1051, |
| 352 | cache_read_input_tokens: 23024, |
| 353 | cache_creation_input_tokens: 4267, |
| 354 | total_cost_usd: 0.038811450000000004, |
| 355 | tool_uses: { |
| 356 | bash: 2, |
| 357 | codereview: 1, |
| 358 | done: 2, |
| 359 | patch: 1, |
| 360 | title: 1, |
| 361 | }, |
| 362 | }, |
| 363 | initial_commit: "a6c5a08a451ef1082774a7affb6af58775e7bc16", |
| 364 | title: "Add a line to dummy.txt and commit the change", |
| 365 | hostname: "MacBook-Pro-9.local", |
| Philip Zeyliger | c72fff5 | 2025-04-29 20:17:54 +0000 | [diff] [blame] | 366 | session_id: "dummy-session", |
| 367 | ssh_available: false, |
| Pokey Rule | 8cac59a | 2025-04-24 12:21:19 +0100 | [diff] [blame] | 368 | working_dir: "/Users/pokey/src/spaghetti", |
| 369 | os: "darwin", |
| 370 | git_origin: "git@github.com:pokey/spaghetti.git", |
| 371 | inside_hostname: "MacBook-Pro-9.local", |
| 372 | inside_os: "darwin", |
| 373 | inside_working_dir: "/Users/pokey/src/spaghetti", |
| Philip Zeyliger | 99a9a02 | 2025-04-27 15:15:25 +0000 | [diff] [blame] | 374 | outstanding_llm_calls: 0, |
| 375 | outstanding_tool_calls: [], |
| Pokey Rule | 8cac59a | 2025-04-24 12:21:19 +0100 | [diff] [blame] | 376 | }; |