lingoose

module
v0.1.0-beta.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 5, 2024 License: MIT

README

lingoose

🪿 LinGoose Build Status GoDoc Go Report Card GitHub release

What is LinGoose?

LinGoose is a Go framework for building awesome AI/LLM applications.

  • LinGoose is modular — You can import only the modules you need to build your application.
  • LinGoose is an abstraction of features — You can choose your preferred implementation of a feature and/or create your own.
  • LinGoose is a complete solution — You can use LinGoose to build your AI/LLM application from the ground up.

Quick start

  1. Initialise a new go module
mkdir example
cd example
go mod init example
  1. Create your first LinGoose application
package main

import (
  "context"
  "fmt"

  "github.com/henomis/lingoose/llm/openai"
)

func main() {

  llm := openai.NewCompletion()

  response, err := llm.Completion(context.Background(), "Tell me a joke about geese")
  if err != nil {
    panic(err)
  }

  fmt.Println(response)

}
  1. Install the Go dependencies
go mod tidy
  1. Start the example application
export OPENAI_API_KEY=your-api-key

go run .

A goose fills its car with goose-line!

Reporting Issues

If you think you've found a bug, or something isn't behaving the way you think it should, please raise an issue on GitHub.

Contributing

We welcome contributions, Read our Contribution Guidelines to learn more about contributing to LinGoose

License

© Simone Vellei, 2023~time.Now() Released under the MIT License

Directories

Path Synopsis
Package chat provides a chat prompt template.
Package chat provides a chat prompt template.
Package decoder provides a set of decoders to decode the output of a command
Package decoder provides a set of decoders to decode the output of a command
examples
assistant command
chat/functions command
chat/simple command
linglet/sql command
llm/cache command
llm/cohere command
llm/llamacpp command
llm/mock command
loader/csv command
loader/pubmed command
loader/whisper command
pipeline/chat command
pipeline/memory command
pipeline/openai command
pipeline/simple command
pipeline/sql command
prompt/chat command
prompt/hello command
prompt/simple command
prompt/whisper command
rag command
thread/cohere command
thread/ollama command
linglet
sql
llm
mock
Package llmmock provides a mock implementation of the LLM interface.
Package llmmock provides a mock implementation of the LLM interface.
openai
Package openai provides a wrapper around the OpenAI API.
Package openai provides a wrapper around the OpenAI API.
memory
ram
Package ram provides a memory storage that stores data in RAM.
Package ram provides a memory storage that stores data in RAM.
Package pipeline provides a way to chain multiple llm executions.
Package pipeline provides a way to chain multiple llm executions.
qa
sql
Package prompt provides a easy way to format a prompt using the Go template engine.
Package prompt provides a easy way to format a prompt using the Go template engine.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL