Skip to content

Commit e39a335

Browse files
committed
Remove user-specific changes.
1 parent 9919a2e commit e39a335

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

libs/oci/tests/integration_tests/chat_models/test_tool_calling.py

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@
6262
from langchain_oci.chat_models import ChatOCIGenAI
6363

6464
def default_compartment():
65-
return "ocid1.tenancy.oc1..aaaaaaaa7ayxuw32vjb64hbxtouarftwtwb2uat5x5mf4hu7cvzaesfrebrq"
65+
return "<compartment_ocid>" # for convenience
6666

6767
def get_weather(city: str) -> str:
6868
"""Get the current weather for a given city name."""
@@ -162,9 +162,7 @@ def test_tool_calling_no_infinite_loop(model_id: str, weather_tool: StructuredTo
162162
SystemMessage(content=system_msg),
163163
HumanMessage(content="What's the weather in Chicago?"),
164164
]
165-
},
166-
config={"recursion_limit": 25}, # Allow enough recursion for multi-step
167-
165+
}
168166
)
169167

170168
messages = result["messages"]
@@ -217,7 +215,7 @@ def test_tool_calling_no_infinite_loop(model_id: str, weather_tool: StructuredTo
217215
@pytest.mark.requires("oci")
218216
def test_meta_llama_tool_calling(weather_tool: StructuredTool):
219217
"""Specific test for Meta Llama models to ensure fix works."""
220-
model_id = "meta.llama-4-scout-17b-16e-instruct" # gets recursion error
218+
model_id = "meta.llama-4-scout-17b-16e-instruct"
221219

222220
agent = create_agent(model_id, weather_tool)
223221

@@ -524,6 +522,6 @@ def should_continue(state: MessagesState):
524522
# Set your desired defaults here or fetch them by any required means.
525523
# You may also load from a local file, IDE Run Config, etc.
526524
os.environ.setdefault("OCI_REGION", "us-chicago-1") # Edit as appropriate
527-
os.environ.setdefault("OCI_COMP", "ocid1.tenancy.oc1..aaaaaaaa7ayxuw32vjb64hbxtouarftwtwb2uat5x5mf4hu7cvzaesfrebrq") # Edit as appropriate
525+
os.environ.setdefault("OCI_COMP", "<compartment_ocid>") # Edit as appropriate
528526
# This runs all tests in this file if you run it as a script in your IDE.
529527
pytest.main([__file__])

0 commit comments

Comments
 (0)