Towards the end of Parashat Lekh-Lekha, God instructs Avraham Avinu with regard to the mitzva of berit mila (circumcision). He introduces His command by enjoining the patriarch, "Walk before Me and be complete" (17:1). What does this imperative mean, and how does it relate to circumcision?
The Midrash contrasts the imperative, "walk before Me" with the Torah's description of Noach, "Noach walked with God" (6:9). To explain the difference between walking "before" and "with" the Almighty, the Midrash draws an analogy to a king who walks with his two sons. He has the older, mature son walk in front to lead the way, while the younger, more dependent child walks beside the father clutching tightly onto his hand. Similarly, God asks Avraham to walk in front of Him, as it were, while Noach walked at the Almighty's side, holding on tightly. Avraham, the "older son," served as God's ambassador on earth, preaching His existence and teaching His laws. Noach, by contrast, lived a private life of piety, sheltering himself from the winds of corruption blowing all around him. Thus, "walk before Me" refers to Avraham's mission as publicizing monotheistic ideology and God's ethical code to mankind.
How may we understand the second charge, "be complete" - "heyei tamim"? This same term arises much later in Chumash, in Parashat Shoftim, amidst the Torah's discussion of prohibited forms of magic and sorcery: "When you enter the land that the Lord your God is giving you, you shall not learn to imitate the abhorrent practices of those nations. Let no one be found among you who consigns his son or daughter to the fire, or who is an augur, a soothsayer, a diviner, a sorcerer, one who casts spells… You must be complete ['tamim'] with the Lord your God" (Devarim 18:9-13). "Tamim" in this context may perhaps denote steadfast resistance to the influence of one's surroundings. While the other nations consult all types of superstitious practitioners, Am Yisrael was to cling tight to its heritage and oppose these practices. Similarly, the Torah describes Noach as "'tamim' in his generation." Noach's greatness was manifest most prominently in his ability to withstand the forces of evil that prevailed in his time and remain pious and just. Thus, God here encourages Avraham to hold firm to his principles, even when confronted by foreign influence.
We must now address our final question: how do these instructions relate to the mitzva of mila?
Rav Kook ("Midbar Shur," p. 197) and others have noted that the requirement of circumcision posed a particularly difficult challenge for Avraham Avinu. As mentioned, he served as a public religious figure, one who spent a good deal of his life meeting people of other beliefs and interacting with them in an effort to spread the teachings of ethical monotheism. A physical blemish as part of religious ritual would effectively erect a solid barrier between Avraham and his contemporaries. It means a permanent symbol of his essential difference from them, as he becomes distinct not only in ideology, but physically, as well. Moreover, people may be discouraged from meeting with Avraham in fear that he would impose this practice upon them. We may add that circumcision serves as a powerful symbol of ethnic isolation, Am Yisrael's commitment to reproduce only with those from its own kin. Undoubtedly, fulfilling this new mitzva would impair Avraham's ability to fulfill his life's mission of disseminating the belief in God. Rav Kook explains that this difficulty prompted Avraham Avinu to consult with his comrades with regard to this obligation, as Chazal claim (see Rashi and Midrash Tanchuma, beginning of Parashat Vayera).
It is precisely this challenge that the Almighty acknowledges in His opening remarks to Avraham Avinu when introducing the mitzva of berit mila: "Walk before Me and be 'tamim.'" God bids Avraham to remain loyal to both conflicting responsibilities: his role as the Almighty's spokesman, and His distinctiveness and firm opposition to the pagan theologies and unethical norms of his time. To the best of his ability, Avraham must simultaneously fulfill both roles - actively engaging in society while firmly opposing the values (or lack thereof) it represents. His interaction with those of beliefs antithetical to his own was not to - and did not - cause his personal resolve to fade or ironclad faith to diminish.