You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to reuse this example from docs in order to create custom categories but it throws error. Here's my code:
custom_categories= [
{"cooking": "For users interested in cooking, including recipes, cooking tips, and culinary experiences."},
{"fitness": "Includes content related to fitness, such as workouts, exercises, and fitness tips."}
]
messages= [
{"role" : "user", "content" : "Hi, my name is Alice. I love to play badminton."},
{"role" : "assistant", "content" : "Hello Alice! It's nice to meet you. Badminton is such an amazing sport. How can I assist you today?"},
{"role" : "user", "content" : "I am a fitness freak, I go to gym daily."},
{"role" : "assistant", "content" : "That's great! Regular exercise is very beneficial for health."},
{"role" : "user", "content" : "Because of my gym plan, I mostly cook at home."},
{"role" : "assistant", "content" : "Cooking at home is a good way to ensure you have a balanced diet."}
]
config= {
"llm": # defining secrets for llm"embedder": # secrets for embedder
}
frommem0importMemorym=Memory.from_config(config)
m.add(messages, user_id="alice", custom_categories=custom_categories)
Hey @uahmad235, The doc refers to use custom_categories for the platform and not OSS package. So you can switch to platform by passing api_key in order to use custom_categories.
🐛 Describe the bug
I am trying to reuse this example from docs in order to create custom categories but it throws error. Here's my code:
Here's the error I get:
The text was updated successfully, but these errors were encountered: