Recent Releases of stormtrooper

stormtrooper - v1.0.0

New in 1.0.0

A couple of highlights from the new version include:

Trooper

The brand new Trooper interface allows you not to have to specify what model type you wish to use. Stormtrooper will automatically detect the model type from the specified name.

```python from stormtrooper import Trooper

This loads a setfit model

model = Trooper("all-MiniLM-L6-v2")

This loads an OpenAI model

model = Trooper("gpt-4")

This loads a Text2Text model

model = Trooper("google/flan-t5-base") ```

Unified zero and few-shot classification

You no longer have to specify whether a model should be a few or a zero-shot classifier when initialising it. If you do not pass any training examples, it will be automatically assumed that the model should be zero-shot.

```python

This is a zero-shot model

model.fit(None, ["dog", "cat"])

This is a few-shot model

model.fit(["he was a good boy", "just lay down on my laptop"], ["dog", "cat"]) ```

MKDocs

Our documentation has now been migrated to MKDocs from Sphinx for simplicity's sake.

- Python
Published by x-tabdeveloping over 1 year ago