index.as_chat_engine()
since we now have a retriever instead of an index. Anyone know best practices for combining the two? Or would I have to create my own chat pipeline?from llama_index.core.chat_engine import CondensePlusContextChatEngine chat_engine = CondensePlusContextChatEngine.from_defaults(retriever, llm=llm, ...)
BadRequestError('Error code: 400 - {\'error\': {\'message\': "The response was filtered due to the prompt triggering Azure OpenAI\'s content management policy. Please modify your prompt and retry. To learn more about our content filtering policies please read our documentation: https://go.microsoft.com/fwlink/?linkid=2198766", \'type\': None, \'param\': \'prompt\', \'code\': \'content_filter\', \'status\': 400, \'innererror\': {\'code\': \'ResponsibleAIPolicyViolation\', \'content_filter_result\': {\'hate\': {\'filtered\': False, \'severity\': \'safe\'}, \'jailbreak\': {\'filtered\': True, \'detected\': True}, \'self_harm\': {\'filtered\': False, \'severity\': \'safe\'}, \'sexual\': {\'filtered\': False, \'severity\': \'safe\'}, \'violence\': {\'filtered\': False, \'severity\': \'safe\'}}}}}')
chat
or _run_c3
functions in the CondensePlusContextChatEngine class to first decompose the query and then recombine as the full context before giving it to the LLM to respond.. Would love to hear if you think this is silly at all π