acsresearch / interlab

MIT License
17 stars 2 forks source link

Nested prompt visualization #15

Closed gavento closed 1 year ago

gavento commented 1 year ago

Add FormatStr class that acts as a string with format fields (like in Python f-string), but remembers the replaced parts and distinguishes them (colors them differently) in the context log.

TODOs:

An example: image

gavento commented 1 year ago

Would merge as is. Not sure if this should become part of core (interlab.text) or contrib/experimental (but could be used in core agents and memories - should be non-intrusive if used at the highest level of formatting).