Skip to content

Commit

Permalink
Merge branch 'main' of github.com:probcomp/hfppl
Browse files Browse the repository at this point in the history
  • Loading branch information
alex-lew committed Sep 12, 2023
2 parents 9498add + 279ce5c commit ea80e31
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 1 addition & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
# LLaMPPL + HuggingFace

<div align="center">
[![docs](https://github.com/probcomp/hfppl/actions/workflows/docs.yml/badge.svg)](https://probcomp.github.io/hfppl)
</div>

LLaMPPL is a research prototype for language model probabilistic programming: specifying language generation tasks by writing probabilistic programs that combine calls to LLMs, symbolic program logic, and probabilistic conditioning. To solve these tasks, LLaMPPL uses a specialized sequential Monte Carlo inference algorithm. This technique, SMC steering, is described in [our recent workshop abstract](https://arxiv.org/abs/2306.03081).

Expand Down Expand Up @@ -96,4 +94,4 @@ Further documentation can be found at https://probcomp.github.io/hfppl.
## Installation
To get started, clone this repository and run `pip install .`

The example `examples/hard_constraints.py` uses LLaMA2, which requires authorization from Meta. To run it, create a file `examples/hf_api_token.py`, with a constant `HF_AUTH_TOKEN` set to your HuggingFace API token. Alternatively, you can switch to a different (open) model by changing the first argument of `CachedCausalLM.from_pretrained` to another HuggingFace model identifier.
The example `examples/hard_constraints.py` uses LLaMA2, which requires authorization from Meta. To run it, create a file `examples/hf_api_token.py`, with a constant `HF_AUTH_TOKEN` set to your HuggingFace API token. Alternatively, you can switch to a different (open) model by changing the first argument of `CachedCausalLM.from_pretrained` to another HuggingFace model identifier.
4 changes: 3 additions & 1 deletion mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ site_name: LLaMPPL Docs

theme:
name: "material"
palette:
scheme: slate

markdown_extensions:
- pymdownx.highlight:
Expand Down Expand Up @@ -33,4 +35,4 @@ nav:
- batching.md
- caching.md
- immutability.md
- Code Reference: reference/
- Code Reference: reference/

0 comments on commit ea80e31

Please sign in to comment.