class LangChainMetadataMarshaller implements MessageMarshaller<LangChainMetadata> {

    private final String typeName;

    public LangChainMetadataMarshaller(String typeName) {
        this.typeName = typeName;
    }

    @Override
    public LangChainMetadata readFrom(ProtoStreamReader reader) throws IOException {<FILL_FUNCTION_BODY>}

    @Override
    public void writeTo(ProtoStreamWriter writer, LangChainMetadata item)
            throws IOException {
        writer.writeString("name", item.name());
        writer.writeString("value", item.value());
    }

    @Override
    public Class<? extends LangChainMetadata> getJavaClass() {
        return LangChainMetadata.class;
    }

    @Override
    public String getTypeName() {
        return typeName;
    }
}

        String name = reader.readString("name");
        String value = reader.readString("value");
        return new LangChainMetadata(name, value);
    
<no_super_class>