Conversation
| iife(f"pushData('{idx}', {{img_data: await getScreenshot()}});") | ||
| time.sleep(0.5) | ||
| d = dict2obj(xpost('http://localhost:5001/pop_data_blocking_', data={'data_id': idx}).json()) | ||
| if 'img_data' in d: return ToolResponse([{'type': 'image_url', 'image_url': d.img_data}]) |
There was a problem hiding this comment.
I might be missing something, but in lisette ToolResponse is
class ToolResponse:
content: list[str,str]Here it seems to be getting a list of dicts? (BTW I rather dislike dataclasses so if there's an option to just make it a normal class that would be nice!)
There was a problem hiding this comment.
ah I messed up the type in lisette. It is supposed to be a list of dicts. and yeah I agree I also dislike dataclasses. When I have time, I'll see if we can move it to a regular class
|
Very nice! BTW when you rely on a updated other lib like lisette here, you should add the current version of that in github as a dep in settings.ini, since when we release that will be what's used. Also put it in big bold letters in the PR so I don't miss it! :) (I've added it now.) |
This PR simplifies the experimental screen capture feature and dialogue helper. It also updates it to use the expected lisette data type for tool responses. Here is a demo of it in action:
screenrecording-2025-11-10_21-10-44.mp4
Requires this PR to be merged: https://github.com/AnswerDotAI/solveit/pull/1103