Package: gato-toolkit
GATO Toolkit: An open-source toolkit for AI alignmentNOTE: This project isunstable, you should consider all functionalityexperimentalandsubject to changewithout warning.This project is intended to further research in AI alignment and the control problem.
In particular, the approach adopted here is inspired by theGATO Framework,
a comprehensive methodology for promoting positive intentions in AI systems worldwide.As this is an ongoing effort, the GATO Toolkit will evolve along with the research.
In this current iteration, the focus is on dataset generation and model alignment.CapabilitiesCome up with new scenarios to testYou can generate all kinds of scenarios ranging from inconsequential personal problems to catastrophic global disasters.
These scenarios serve as the basis for new investigations.Determine an appropriate action for any scenarioOnce you've got a scenario, you can ask the model how it would attempt to handle the situation.Compare different actions to see which is most alignedGiven a particular scenario, you can provide a number of different possible actions to see which one the model believes
is best aligned with the heuristic imperatives.Evaluate the suitability of an action based on its consequencesGiven a particular scenario, action, and result, you can ask the model to assess the effectiveness of that action and
reflect on the repercussions of that action.Break actions down into manageable tasksStarting with a broad action plan, you can have the model break things up into a list of tasks that would be needed
to execute that plan.UsageThis project provides a library of functions that may be useful for all sorts of research tasks in AI alignment.
This functionality can be used directly in Python applications, but we also support two additional interfaces:GATO Toolkit APIGATO Toolkit UIIf you want to develop new applications in Python, this library is probably the right choice. Jump straight to theexamples!But, if you're using a different programming langauge, the API will be your best bet.Finally, if you just want to leverage the existing functionality, have a look at the UI.Also, both of those resources serve as example usage code, so go take a look! 👀If you do want to use this library directly, you'll probably want to interact withGatoServiceclass.
You'll find the essential operations there, and you can see how the lower-level components work by examining the code ingato/service.py.For more information on design and architecture, check out ourdesign doc.ExamplesGenerate a Scenarioimportgato.llmimportgato.serviceasyncdefgenerate_scenario(api_key:str):model=gato.llm.LLM(api_key)service=gato.service.GatoService(model)params=service.create_scenario_parameters()prompt=service.create_scenario_prompt(params)returnawaitservice.create_scenario(prompt)Generate an Actionimportgato.entityimportgato.llmimportgato.serviceasyncdefgenerate_action(api_key:str,scenario:gato.entity.Scenario):model=gato.llm.LLM(api_key)service=gato.service.GatoService(model)prompt=service.create_action_prompt(scenario)returnawaitservice.create_action(prompt)Additional ResourcesGATO FrameworkReinforcement Learning with Heuristic ImperativesContributingContributions to the GATO Toolkit are welcome! Please read ourcontributing guidelinesandcode of conductbefore you start.LicenseMIT