Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
71 commits
Select commit Hold shift + click to select a range
ee3fe4f
Refactor _validate_plan_forward to use option model directly
yichao-liang Apr 1, 2026
58b86cd
Unify backtracking refinement search into shared run_backtracking_ref…
yichao-liang Apr 1, 2026
e7eaf05
Simplify _validate_plan_forward to use run_backtracking_refinement
yichao-liang Apr 1, 2026
43acbf2
Refactor _current_observation/_current_state usage in pybullet_env
yichao-liang Apr 2, 2026
57ef4b8
Add CFG option to load plan sketch from file instead of LLM
yichao-liang Apr 2, 2026
d0ac199
Remove redundant conditions from Place action in boil_plan_sketch
yichao-liang Apr 2, 2026
0cafcd8
Scale target joint value based on switch_joint_scale in PyBulletBoilEnv
yichao-liang Apr 2, 2026
3808337
Refactor _terminal in option model to deduplicate wait-termination logic
yichao-liang Apr 7, 2026
3624d01
Refactor terminal state logging in _OracleOptionModel to simplify con…
yichao-liang Apr 7, 2026
80c8110
Format docstring in get_observation method for improved readability
yichao-liang Apr 7, 2026
d3ad209
Refactor PyBulletEnv for readability and better naming
yichao-liang Apr 7, 2026
5bf6af3
Regroup PyBulletEnv methods by responsibility and update docstring
yichao-liang Apr 7, 2026
59aac01
Refactor PyBulletEnv: extract _domain_specific_step from step()
yichao-liang Apr 8, 2026
f86c0ea
Update PyBulletEnv module docstring for step() refactoring
yichao-liang Apr 8, 2026
9cddb03
Add skip_process_dynamics constructor param to PyBulletEnv
yichao-liang Apr 8, 2026
989cf4e
Extract run_query_sync helper to remove duplicated async-to-sync brid…
yichao-liang Apr 13, 2026
87bbe1c
Refactor main function: extract and modularize setup logic for clarit…
yichao-liang Apr 14, 2026
10f010b
Rename agent explorer to agent_plan for clearer naming
yichao-liang Apr 14, 2026
4076abd
Move AgentSessionMixin into agent_sdk package
yichao-liang Apr 14, 2026
b264291
Add AgentBilevelExplorer for sim-learning experiments
yichao-liang Apr 14, 2026
ee0a2b7
Add explorer-specific sample budget and experiment-plan logging
yichao-liang Apr 16, 2026
a8fb2dd
Add sim-learning approach and synthesis tooling
yichao-liang Apr 16, 2026
f392458
Update experiment configs for sim-learning
yichao-liang Apr 16, 2026
7663d05
Refactor sim-learning: extract primitives, add GT simulator factory
yichao-liang Apr 16, 2026
9970dd4
Fix formatting, pylint, and mypy issues for CI compliance
yichao-liang Apr 16, 2026
8ff80a4
Update test setup to use test tasks for boil environment and refine t…
yichao-liang Apr 16, 2026
54002dd
Refactor combined model in GT simulator
yichao-liang Apr 16, 2026
cb405d9
Fix expected-atoms check to support DerivedPredicates
yichao-liang Apr 17, 2026
6c92572
Skip kinematic reset in PyBullet when only non-kinematic state changed
yichao-liang Apr 17, 2026
c9723f2
Support offline dataset learning in AgentSimLearningApproach
yichao-liang Apr 17, 2026
cccb7e2
Log periodic progress during MCMC parameter fitting
yichao-liang Apr 17, 2026
ec3b9f3
Fix mypy and pylint errors for CI compliance
yichao-liang Apr 17, 2026
e8e3675
Apply yapf, isort, and docformatter across the codebase
yichao-liang Apr 17, 2026
328b4d7
Inline approach configs into parent files in predicatorv3
Apr 28, 2026
6735ac8
Preserve robot joint config across PyBullet state save/restore
Apr 28, 2026
ebb3304
Add 'emcee' to the list of install_requires in setup.py
yichao-liang Apr 28, 2026
0bc5234
Force PyBullet FK refresh and skip redundant finger snap
yichao-liang Apr 29, 2026
e84d788
Apply yapf/docformatter to satisfy CI autoformat check
yichao-liang Apr 29, 2026
8333b0f
Configure predicatorv3 demos for offline-only sim-learning runs
yichao-liang Apr 29, 2026
0b6a4b0
Add jug orientation handling in PyBulletBoilEnv
yichao-liang Apr 29, 2026
1b6c510
Revert getLinkState to PyBullet default (no computeForwardKinematics …
yichao-liang Apr 30, 2026
f0b4692
Add lo/hi bounds to ParamSpec and skip-MCMC support in fit_params
yichao-liang Apr 30, 2026
9c61f3e
Build boil param specs dynamically from CFG with lo/hi bounds
yichao-liang Apr 30, 2026
e08df54
Apply lo/hi clamping and configurable noise scale to oracle perturbation
yichao-liang Apr 30, 2026
e44a850
Update installation instructions and add macOS setup script for PyBullet
yichao-liang Apr 30, 2026
b8df145
Update PyBullet version to 3.2.7 and simplify macOS setup script
yichao-liang May 1, 2026
c033f9c
Refactor liquid color update logic and rename related methods for cla…
yichao-liang May 1, 2026
20a310e
Add more debug logging for CogMan and option execution flow
yichao-liang May 1, 2026
9d6b9e3
Handle PyBullet physics server crashes with env recreation and retry
yichao-liang May 1, 2026
99b38b1
Fix jug orientation handling in PyBulletBoilEnv by restoring rotation…
yichao-liang May 1, 2026
8521882
Update installation instructions and dependencies; remove macOS setup…
yichao-liang May 1, 2026
f998254
Remove mara_robosim dependency from setup.py
yichao-liang May 1, 2026
ea690a2
Merge remote-tracking branch 'origin/master' into sim-learning
yichao-liang May 1, 2026
4e12a17
Fix get_gt_simulator to use env_name instead of normalized name
yichao-liang May 2, 2026
a8105cf
Add before/after MSE, likelihood, and param-delta logging for paramet…
yichao-liang May 2, 2026
2f97798
Use SSE loss and wider walker init so MCMC parameter fitting actually…
yichao-liang May 3, 2026
9f09ff9
Move GT simulator components onto module-globals contract
yichao-liang May 4, 2026
c5d45c2
Soften boil parameter-dependent gates with sigmoid weights
yichao-liang May 4, 2026
95e384f
Add LM warm-start and Hessian identifiability diagnostic
yichao-liang May 4, 2026
195e889
Infer process-feature scope from base-sim residuals
yichao-liang May 4, 2026
124dd94
Skip MCMC and use LM warm-start in boil agent config
yichao-liang May 4, 2026
cc11084
Apply yapf and docformatter formatting
yichao-liang May 4, 2026
465177a
Silence mypy on PyBullet client-id attribute access
yichao-liang May 4, 2026
6e76660
Mark unused action arg in sim_fn to satisfy pylint
yichao-liang May 4, 2026
9415d12
Use per-component diff in _set_state to eliminate robot jitter
yichao-liang May 4, 2026
418fd30
Reposition recreated cups and plugs in coffee _set_domain_specific_state
yichao-liang May 4, 2026
e82df9d
Look up predicates lazily in option-model _abstract_function
yichao-liang May 4, 2026
8b6d709
Rename 'kinematics-only' to 'base-sim-only' in docs and test names
yichao-liang May 4, 2026
abc448f
Tighten _robot_matches_state atol so set_state hint forces reset
yichao-liang May 4, 2026
58f44f6
Fix flaky test_glib_explorer and test_demo_dataset_loading under pyte…
yichao-liang May 4, 2026
7bc4443
Add unit tests for _robot_matches_state atol and pybullet_helpers.obj…
yichao-liang May 4, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
import os
from typing import Any, Dict, List, Optional, Set, Union

from predicators.agent_sdk.session_manager import AgentSessionManager
from predicators.agent_sdk.session_manager import AgentSessionManager, \
run_query_sync
from predicators.agent_sdk.tools import ToolContext, create_mcp_tools, \
get_allowed_tool_list
from predicators.explorers import create_explorer
Expand Down Expand Up @@ -127,12 +128,18 @@ def _ensure_agent_session(self) -> None:
tools=tools,
)

extra_names = [
getattr(t, "name", "")
for t in self._tool_context.extra_mcp_tools
]
self._agent_session = AgentSessionManager(
system_prompt=self._get_agent_system_prompt(),
mcp_server=mcp_server,
log_dir=self._get_log_dir(),
model_name=CFG.agent_sdk_model_name,
allowed_tools=get_allowed_tool_list(tool_names),
allowed_tools=get_allowed_tool_list(tool_names,
extra_names=extra_names
or None),
)

if self._agent_session_id is not None:
Expand Down Expand Up @@ -179,26 +186,18 @@ def _query_agent_sync(self, message: str) -> List[Dict[str, Any]]:
"""Synchronous wrapper for async agent query."""
self._ensure_agent_session()
assert self._agent_session is not None
try:
loop = asyncio.get_event_loop()
if loop.is_running():
import nest_asyncio # type: ignore[import-untyped,import-not-found] # pylint: disable=import-outside-toplevel
nest_asyncio.apply()
return loop.run_until_complete(
self._agent_session.query(message))
return loop.run_until_complete(self._agent_session.query(message))
except RuntimeError:
return asyncio.run(self._agent_session.query(message))
return run_query_sync(self._agent_session, message)

def _create_agent_explorer(
self,
predicates: Set[Predicate],
options: Set[ParameterizedOption],
name: str = "agent_plan",
) -> BaseExplorer:
"""Create an agent explorer with tool_context and agent_session."""
self._ensure_agent_session()
return create_explorer(
"agent",
name,
predicates,
options,
self._types, # type: ignore[attr-defined]
Expand Down
Loading
Loading