Advertisement
Guest User

Untitled

a guest
Jul 20th, 2023
61
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.38 KB | None | 0 0
  1. >>> from gpt4all import GPT4All
  2. >>> model = GPT4All('orca-mini-3b.ggmlv3.q4_0', model_path='./', n_threads = 8)
  3. Found model file at ./orca-mini-3b.ggmlv3.q4_0.bin
  4. llama.cpp: loading model from ./orca-mini-3b.ggmlv3.q4_0.bin
  5. llama_model_load_internal: format = ggjt v3 (latest)
  6. llama_model_load_internal: n_vocab = 32000
  7. llama_model_load_internal: n_ctx = 2048
  8. llama_model_load_internal: n_embd = 3200
  9. llama_model_load_internal: n_mult = 240
  10. llama_model_load_internal: n_head = 32
  11. llama_model_load_internal: n_layer = 26
  12. llama_model_load_internal: n_rot = 100
  13. llama_model_load_internal: ftype = 2 (mostly Q4_0)
  14. llama_model_load_internal: n_ff = 8640
  15. llama_model_load_internal: n_parts = 1
  16. llama_model_load_internal: model size = 3B
  17. llama_model_load_internal: ggml ctx size = 0.06 MB
  18. llama_model_load_internal: mem required = 2862.72 MB (+ 682.00 MB per state)
  19. llama_new_context_with_model: kv self size = 650.00 MB
  20. >>> with model.chat_session():
  21. ... while True:
  22. ... user_message = input("Human: ")
  23. ... for token in model.generate(user_message, streaming = True, n_batch = 100, reverse_prompts = [" Biden"]):
  24. ... print(token, end="", flush=True)
  25. ... print()
  26. ...
  27. Human: Who is the president of the US?
  28. As of August 2021, the President of the United States is Joe
  29. Human:
  30.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement