KoboldAI / KoboldAI-Client

https://koboldai.com
GNU Affero General Public License v3.0
3.45k stars 743 forks source link

[Enhancement] Add a Dramatron scenario for Script Writing #385

Open bennmann opened 12 months ago

bennmann commented 12 months ago

Google finally opened their Dramatron code sometime within the last few months: https://colab.research.google.com/github/deepmind/dramatron/blob/main/colab/dramatron.ipynb

"Dramatron is a script writing tool that leverages large language models. It uses hierarchical generation to ensure long range consistency across the entire script. The work was published as a pre-print in Mirowski, Mathewson et al. (2022) https://dl.acm.org/doi/10.1145/3544548.3581225."

Co-authorship with Dramatron proceeds as follows: a writer starts with a log line, and then
generates the title, characters, plot outline, location descriptions
and each scene’s dialogue step-by-step. At each step, the writer can
take one, or several, of the following operations, as many times as
desired:
• Generate a new suggestion (i.e., run the LLM again with the
same prompt).
• Continue generating from the end of the previous generation,
similarly to typical “flat” LLM generation.
• Manually edit some or all of the output generated by the
LLM.
The writer can furthermore perform these operations by stepping
forward and back in the Dramatron hierarchy. For example, they
could: 1) generate a title, 2) generate a new title, 3) edit the title,
4) generate a list of characters, 5) edit the characters by removing
one character and changing the description of another, 6) generate
a plot outline, 7) edit the plot by removing part of the narrative
arc, 8) generate a continuation of that edited plot, 9) go back and
rewrite the log line, etc. This co-writing approach allows the human
and Dramatron to both contribute to the authorship of a script.
Following these operations, the human author could further edit
and format to finalize a script

A scenario like this for KoboldAI would be a dream tool for me and hopefully other story creators, and most of the code is readable and easily transferable into Kobold. I am sad to say it is beyond me to actually make any pull request and try to rework this into a pull.

If anyone else has the ability or desire, please upvote this post to add this kind of Dramatron scenario to kobold.