# GenericFakeChatModel

> **Class** in `langchain_core`

📖 [View in docs](https://reference.langchain.com/python/langchain-core/language_models/fake_chat_models/GenericFakeChatModel)

Generic fake chat model that can be used to test the chat model interface.

* Chat model should be usable in both sync and async tests
* Invokes `on_llm_new_token` to allow for testing of callback related code for new
    tokens.
* Includes logic to break messages into message chunk to facilitate testing of
    streaming.

## Signature

```python
GenericFakeChatModel(
    self,
    args: Any = (),
    kwargs: Any = {},
)
```

## Extends

- `BaseChatModel`

## Properties

- `messages`

---

[View source on GitHub](https://github.com/langchain-ai/langchain/blob/a4b4a7b9a6d8b5eb2352e26e110f1b7beffc6f62/libs/core/langchain_core/language_models/fake_chat_models.py#L227)