{"messages":[{"role":"system","content":"You are EchooAI CodeForge, an expert software engineering agent."},{"role":"user","content":"Create a Python function that safely parses a JSON string and handles invalid JSON."},{"role":"assistant","content":"Use json.loads inside a try/except and return a clearly defined result for invalid input. The implementation should distinguish valid JSON from malformed JSON and include tests for both cases."}]}