Skip to content

armgit / letta

Public Imported from GitHub
0

Platform for stateful agents: AI with advanced memory that can learn and self-improve over time.

fix: remove requirement to specify version in `~/.memgpt/config` (#1337)

Sarah Woodersb2e42a4a5fe7
diff --git a/memgpt/cli/cli.py b/memgpt/cli/cli.py
index 2e51e0829..cd490820f 100644
--- a/memgpt/cli/cli.py
+++ b/memgpt/cli/cli.py
@@ -506,12 +506,6 @@ def run(
else: # load config
config = MemGPTConfig.load()
- # force re-configuration is config is from old version
- if config.memgpt_version is None: # TODO: eventually add checks for older versions, if config changes again
- typer.secho("MemGPT has been updated to a newer version, so re-running configuration.", fg=typer.colors.YELLOW)
- configure()
- config = MemGPTConfig.load()
-
# read user id from config
ms = MetadataStore(config)
user = create_default_user_or_exit(config, ms)
diff --git a/memgpt/migrate.py b/memgpt/migrate.py
index 5d424ddb4..2266da261 100644
--- a/memgpt/migrate.py
+++ b/memgpt/migrate.py
@@ -84,9 +84,8 @@ def config_is_compatible(data_dir: str = MEMGPT_DIR, allow_empty=False, echo=Fal
version = None
if version is None:
- if echo:
- typer.secho(f"Current config version is missing", fg=typer.colors.RED)
- return False
+ # no version -- assume pre-determined config (does not need to be migrated)
+ return True
elif version_less_than(version, VERSION_CUTOFF):
if echo:
typer.secho(f"Current config version ({version}) is older than migration cutoff ({VERSION_CUTOFF})", fg=typer.colors.RED)