Prevent profile file from being overridden by defaults #1615
  Add this suggestion to a batch that can be applied as a single commit.
  This suggestion is invalid because no changes were made to the code.
  Suggestions cannot be applied while the pull request is closed.
  Suggestions cannot be applied while viewing a subset of changes.
  Only one suggestion per line can be applied in a batch.
  Add this suggestion to a batch that can be applied as a single commit.
  Applying suggestions on deleted lines is not supported.
  You must change the existing code in this line in order to create a valid suggestion.
  Outdated suggestions cannot be applied.
  This suggestion has been applied or marked resolved.
  Suggestions cannot be applied from pending reviews.
  Suggestions cannot be applied on multi-line comments.
  Suggestions cannot be applied while the pull request is queued to merge.
  Suggestion cannot be applied right now. Please check back later.
  
    
  
    
Describe the changes you have made:
dependent on #1612
Previously it was keeping the default:
profile_path: ~/.openinterpreter\default_profile.py
because interpreter.profile_path is not an attribute that would be set
within the profile file, but is a property of that file.
Previously, when loading a custom profile via --profile, its settings
could be overridden by defaults from the initial Profile() instance
because argparse was initialized with those defaults, and
only None-valued arguments would be updated from the custom profile.
This caused issues like custom model settings being reset to the default
claude-3-5-sonnet-20241022.
This change:
This ensures profile settings take precedence over defaults while
still allowing CLI arguments to override profile settings.
Example:
Before: Custom profile with model="gpt-4o-mini" would be overridden
by default model="claude-3-5-sonnet-20241022" unless --model was
explicitly set on command line.
After: Custom profile settings are preserved unless explicitly
overridden by command line arguments.
The provider auto-detection still works as expected:
Reference any relevant issues (e.g. "Fixes #000"):
Pre-Submission Checklist (optional but appreciated):
docs/CONTRIBUTING.mddocs/ROADMAP.mdOS Tests (optional but appreciated):