mirror of
https://github.com/aljazceru/gpt-engineer.git
synced 2025-12-18 13:15:00 +01:00
changed feedback collection from opt-out to opt-in (#423)
Co-authored-by: Vincent Desktop <soellner.vincent@gmail.com>
This commit is contained in:
@@ -23,8 +23,8 @@ def send_learning(learning: Learning):
|
|||||||
|
|
||||||
|
|
||||||
def collect_learnings(model: str, temperature: float, steps: List[Step], dbs: DBs):
|
def collect_learnings(model: str, temperature: float, steps: List[Step], dbs: DBs):
|
||||||
if os.environ.get("COLLECT_LEARNINGS_OPT_OUT") in ["true", "1"]:
|
if os.environ.get("COLLECT_LEARNINGS_OPT_IN") in ["false", "1"]:
|
||||||
print("COLLECT_LEARNINGS_OPT_OUT is set to true, not collecting learning")
|
print("COLLECT_LEARNINGS_OPT_IN is set to false, not collecting learning")
|
||||||
return
|
return
|
||||||
|
|
||||||
learnings = extract_learning(
|
learnings = extract_learning(
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ from gpt_engineer.steps import gen_code
|
|||||||
|
|
||||||
|
|
||||||
def test_collect_learnings(monkeypatch):
|
def test_collect_learnings(monkeypatch):
|
||||||
monkeypatch.setattr(os, "environ", {"COLLECT_LEARNINGS_OPT_OUT": "false"})
|
monkeypatch.setattr(os, "environ", {"COLLECT_LEARNINGS_OPT_IN": "true"})
|
||||||
monkeypatch.setattr(rudder_analytics, "track", MagicMock())
|
monkeypatch.setattr(rudder_analytics, "track", MagicMock())
|
||||||
|
|
||||||
model = "test_model"
|
model = "test_model"
|
||||||
|
|||||||
Reference in New Issue
Block a user