Comments (2)
The way I fixed this is by removing the temperature parameter. However, somehow, somewhere in the pipeline, the instantiation of the bedrock model turns into a string, and I get an error about 'str' object has no attribute .invoke_model.
I will fix this next and raise an issue about it.
from scrapegraph-ai.
Okay, here is the problem.
In this chunk of code:
graph_config = {
"llm": {
"client": "client_name",
"model": "bedrock/anthropic.claude-3-sonnet-20240229-v1:0"
}
}
"client" needs to map to a boto3 instance of bedrock client. The langchain library for aws has the method init_chat_model(), which will not throw an error if you pass in a string for the client, but it will throw an error when trying to use llm_model.generate_prompt() saying that "AttributeError: 'str' object has no attribute 'to_messages'"
I am going to keep going down this rabbit hole to see if I can solve this and continue reporting on this thread.
Edit: Unfortunately, this is incorrect, and instantiating "client_name" as the actual instance of the boto3 bedrock client did not fix it. I would appreciate documentation on what client name is.
from scrapegraph-ai.
Related Issues (20)
- i am getting the below while running for ollama model HOT 7
- Token count implementation in ParseNode splits text on spaces which is not correct HOT 1
- When I use examples/deepseek/smart_scraper_deepseek.py ,I have a error. HOT 4
- v1.17.0b5: No module named 'PIL' HOT 4
- Chunking support for ScriptCreatorGraph HOT 4
- Support for OpenAI Assistants API HOT 2
- Provider bedrock is not supported when trying to use bedrock examples listed in repo. HOT 6
- ValueError: Error raised by bedrock service: 'str' object has no attribute 'invoke_model' HOT 6
- It can´t scrape URLs from the source HOT 8
- Executing RAG Node HOT 2
- Not getting extraction results after upgrading from 1.6.1 to 1.18.1 HOT 1
- SmartScraperGraph with Gemini: Provider google is not supported in SmartScraperGraph HOT 2
- Implement tokenization for Ollama models in refactoring-tokenization branch HOT 6
- SmartScraperGraph Initialization Error HOT 3
- [Feature Request] Add a hook to customize "wait_for_load_state" behavior HOT 1
- return number of input and output tokens with the model HOT 2
- Can you collect user usage data from within the library and write it to readme HOT 4
- Cerebras and SambaNova
- Bedrock model copy recursion HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from scrapegraph-ai.