You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: accesspolicy_kind_gen.go
    path of file: ./repos/grafana/pkg/kinds/accesspolicy
    
    the code of the file until where you have to start completion: // Code generated - EDITING IS FUTILE. DO NOT EDIT.
//
// Generated by:
//     kinds/gen.go
// Using jennies:
//     CoreKindJenny
//
// Run 'make gen-cue' from repository root to regenerate.

package accesspolicy

import (
	"github.com/grafana/kindsys"
	"github.com/grafana/thema
    
func NewKind(rt *thema.Runtime, opts ...thema.BindOption) (*Kind, error) {
	def, err := cuectx.LoadCoreKindDef(rootrel, rt.Context(), nil)
	if err != nil {
		return nil, err
	}

	k := &Kind{}
	k.Core, err = kindsys.BindCore(rt, def, opts...)
	if err != nil {
		return nil, err
	}
	// Get the thema.Schema that the meta says is in the current version (which
	// codegen ensures is always the latest)
	cursch := thema.SchemaP(k.Core.Lineage(), def.Properties.CurrentVersion)
	tsch, err := thema.BindType(cursch, &Resource{})
	if err != nil {
		// Should be unreachable, modulo bugs in the Thema->Go code generator
		return nil, err
	}

	k.jcodec = vmux.NewJSONCodec("accesspolicy.json")
	k.lin = tsch.ConvergentLineage()
	k.valmux = vmux.NewValueMux(k.lin.TypedSchema(), k.jcodec)
	return k, nil
}